Uh oh!
There was an error while loading. Please reload this page.
[SPARK-21016][core]Improve code fault tolerance for converting string to number - #18238
[SPARK-21016][core]Improve code fault tolerance for converting string to number#1823810110346 wants to merge 1 commit into
Conversation
wzhfy
commented
Jun 10, 2017
If a string has a leading or trailing space, it's expected it cannot be converted to a number. |
But it can be converted to double. |
kiszk
commented
Jun 10, 2017
It would be good to do the same thing for |
HyukjinKwon
commented
Jun 10, 2017
I think it will be more persuasive if there are some cases where users mistakenly write wrong values for both numbers and booleans. Personally, I haven't got any errors about this before (more than two years in production / development). |
10110346
commented
Jun 12, 2017
@HyukjinKwon I agree with you ,but i think if add |
gatorsmile
commented
Jun 12, 2017
Although it is not a common user error, it does not hurt to add an extra |
gatorsmile
commented
Jun 12, 2017
ok to test |
SparkQA
commented
Jun 12, 2017
Test build #77917 has started for PR 18238 at commit |
SparkQA
commented
Jun 12, 2017
Test build #77921 has finished for PR 18238 at commit
|
srowen
commented
Jun 12, 2017
I'm neutral. Accepting bad input isn't usually a great idea, though in this case, I can't see much harm. It's not ambiguous. |
SparkQA
commented
Jun 12, 2017
Test build #77930 has finished for PR 18238 at commit
|
gatorsmile
commented
Jun 12, 2017
retest this please |
SparkQA
commented
Jun 12, 2017
Test build #77944 has finished for PR 18238 at commit
|
SparkQA
commented
Jun 13, 2017
Test build #77966 has started for PR 18238 at commit |
10110346
commented
Jun 13, 2017
Jenkins, retest this please |
SparkQA
commented
Jun 13, 2017
Test build #77982 has finished for PR 18238 at commit
|
gatorsmile
commented
Jun 13, 2017
Thanks! Merging to master. |
…g to number ## What changes were proposed in this pull request? When converting `string` to `number`(int, long or double), if the string has a space before or after,will lead to unnecessary mistakes. ## How was this patch tested? unit test Author: liuxian <liu.xian3@zte.com.cn> Closesapache#18238 from 10110346/lx-wip-0608.
What changes were proposed in this pull request?
When converting
stringtonumber(int, long or double), if the string has a space before or after,will lead to unnecessary mistakes.How was this patch tested?
unit test