[SPARK-29101][SQL][2.4] Fix count API for csv file when DROPMALFORMED mode is selected#25843
Closed
sandeep-katta wants to merge 1 commit intoapache:branch-2.4from
Closed
[SPARK-29101][SQL][2.4] Fix count API for csv file when DROPMALFORMED mode is selected#25843sandeep-katta wants to merge 1 commit intoapache:branch-2.4from
sandeep-katta wants to merge 1 commit intoapache:branch-2.4from
Conversation
Member
|
ok to test |
Member
|
Thank you for backporting, @sandeep-katta . |
Member
|
cc @HyukjinKwon |
|
Test build #110964 has finished for PR 25843 at commit
|
Member
|
retest this please |
|
Test build #110966 has finished for PR 25843 at commit
|
Member
|
Retest this please. |
|
Test build #110969 has finished for PR 25843 at commit
|
Member
|
retest this please |
|
Test build #110980 has finished for PR 25843 at commit
|
dongjoon-hyun
approved these changes
Sep 19, 2019
Member
dongjoon-hyun
left a comment
There was a problem hiding this comment.
+1, LGTM. Merged to branch-2.4
Thank you, @sandeep-katta , @HyukjinKwon , @srowen !
dongjoon-hyun
pushed a commit
that referenced
this pull request
Sep 19, 2019
… mode is selected
### What changes were proposed in this pull request?
#DataSet
fruit,color,price,quantity
apple,red,1,3
banana,yellow,2,4
orange,orange,3,5
xxx
This PR aims to fix the below
```
scala> spark.conf.set("spark.sql.csv.parser.columnPruning.enabled", false)
scala> spark.read.option("header", "true").option("mode", "DROPMALFORMED").csv("fruit.csv").count
res1: Long = 4
```
This is caused by the issue [SPARK-24645](https://issues.apache.org/jira/browse/SPARK-24645).
SPARK-24645 issue can also be solved by [SPARK-25387](https://issues.apache.org/jira/browse/SPARK-25387)
### Why are the changes needed?
SPARK-24645 caused this regression, so reverted the code as it can also be solved by SPARK-25387
### Does this PR introduce any user-facing change?
No,
### How was this patch tested?
Added UT, and also tested the bug SPARK-24645
**SPARK-24645 regression**

Closes #25843 from sandeep-katta/SPARK-29101_branch2.4.
Authored-by: sandeep katta <sandeep.katta2007@gmail.com>
Signed-off-by: Dongjoon Hyun <dhyun@apple.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
#DataSet
fruit,color,price,quantity
apple,red,1,3
banana,yellow,2,4
orange,orange,3,5
xxx
This PR aims to fix the below
This is caused by the issue SPARK-24645.
SPARK-24645 issue can also be solved by SPARK-25387
Why are the changes needed?
SPARK-24645 caused this regression, so reverted the code as it can also be solved by SPARK-25387
Does this PR introduce any user-facing change?
No,
How was this patch tested?
Added UT, and also tested the bug SPARK-24645
SPARK-24645 regression
