[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-16 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/carbondata/pull/1656


---


[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-14 Thread pawanmalwal
Github user pawanmalwal commented on a diff in the pull request:

https://github.com/apache/carbondata/pull/1656#discussion_r156907109
  
--- Diff: 
integration/spark2/src/main/scala/org/apache/spark/sql/execution/CastExpressionOptimization.scala
 ---
@@ -82,6 +109,21 @@ object CastExpressionOptimization {
 }
   }
 
+  def typeCastStringToLongListForDateType(list: Seq[Expression]): 
Seq[Expression] = {
--- End diff --

Handled comments.  Please review.


---


[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-14 Thread pawanmalwal
Github user pawanmalwal commented on a diff in the pull request:

https://github.com/apache/carbondata/pull/1656#discussion_r156907140
  
--- Diff: 
integration/spark2/src/main/scala/org/apache/spark/sql/execution/CastExpressionOptimization.scala
 ---
@@ -67,6 +68,32 @@ object CastExpressionOptimization {
 }
   }
 
+  def typeCastStringToLongForDateType(v: Any): Any = {
--- End diff --

Handled comments.  Please review.


---


[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-14 Thread pawanmalwal
Github user pawanmalwal commented on a diff in the pull request:

https://github.com/apache/carbondata/pull/1656#discussion_r156907084
  
--- Diff: 
integration/spark2/src/main/scala/org/apache/spark/sql/execution/CastExpressionOptimization.scala
 ---
@@ -122,6 +164,13 @@ object CastExpressionOptimization {
 } else {
   Some(CastExpr(c))
 }
+  case d: DateType if t.sameType(StringType) =>
--- End diff --

Handled comment.  Please review.


---


[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-13 Thread ravipesala
Github user ravipesala commented on a diff in the pull request:

https://github.com/apache/carbondata/pull/1656#discussion_r156842298
  
--- Diff: 
integration/spark2/src/main/scala/org/apache/spark/sql/execution/CastExpressionOptimization.scala
 ---
@@ -122,6 +164,13 @@ object CastExpressionOptimization {
 } else {
   Some(CastExpr(c))
 }
+  case d: DateType if t.sameType(StringType) =>
--- End diff --

Merge the case blocks as follows,
```
case TimestampType | DateType
```


---


[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-13 Thread ravipesala
Github user ravipesala commented on a diff in the pull request:

https://github.com/apache/carbondata/pull/1656#discussion_r156841880
  
--- Diff: 
integration/spark2/src/main/scala/org/apache/spark/sql/execution/CastExpressionOptimization.scala
 ---
@@ -82,6 +109,21 @@ object CastExpressionOptimization {
 }
   }
 
+  def typeCastStringToLongListForDateType(list: Seq[Expression]): 
Seq[Expression] = {
--- End diff --

code duplicated, extract common code


---


[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-13 Thread ravipesala
Github user ravipesala commented on a diff in the pull request:

https://github.com/apache/carbondata/pull/1656#discussion_r156841784
  
--- Diff: 
integration/spark2/src/main/scala/org/apache/spark/sql/execution/CastExpressionOptimization.scala
 ---
@@ -67,6 +68,32 @@ object CastExpressionOptimization {
 }
   }
 
+  def typeCastStringToLongForDateType(v: Any): Any = {
--- End diff --

code duplicated, extract common code


---


[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-13 Thread pawanmalwal
GitHub user pawanmalwal reopened a pull request:

https://github.com/apache/carbondata/pull/1656

[CARBONDATA-1247] Block pruning not working for date type column

Block pruning not working for date type column.
Root Cause : Type casting of String for DateType is not handled

Solution: CastExpressionOptimization should handle the casting of String 
for DateType

Be sure to do all of the following checklist to help us incorporate 
your contribution quickly and easily:

 - [X] Any interfaces changed?
 None
 - [X] Any backward compatibility impacted?
 None
 - [X] Document update required?
NA
 - [X] Testing done
Please provide details on 
- Whether new unit test cases have been added or why no new tests 
are required?
- How it is tested? Please attach test report.
- Is it a performance related change? Please attach the performance 
test report.
- Any additional information to help reviewers in testing this 
change.
   Done manual testing
 - [ ] For large changes, please consider breaking it into sub-tasks under 
an umbrella JIRA. 
NA



You can merge this pull request into a Git repository by running:

$ git pull https://github.com/pawanmalwal/carbondata 
date_datatype_block_pruning_issue_fix

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/carbondata/pull/1656.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #1656


commit de83c25a03606a42eac049433798b2cfdfc7b5af
Author: Pawan Malwal 
Date:   2017-12-13T07:31:20Z

[CARBONDATA-1887] Block pruning not working for date type column




---


[GitHub] carbondata pull request #1656: [CARBONDATA-1247] Block pruning not working f...

2017-12-13 Thread pawanmalwal
Github user pawanmalwal closed the pull request at:

https://github.com/apache/carbondata/pull/1656


---