File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/csv Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -88,11 +88,11 @@ object CSVExprUtils {
8888 if (useLegacyParser) {
8989 (s : String ) => new BigDecimal (s.replaceAll(" ," , " " ))
9090 } else {
91- val df = new DecimalFormat (" " , new DecimalFormatSymbols (locale))
92- df .setParseBigDecimal(true )
91+ val decimalFormat = new DecimalFormat (" " , new DecimalFormatSymbols (locale))
92+ decimalFormat .setParseBigDecimal(true )
9393 (s : String ) => {
9494 val pos = new ParsePosition (0 )
95- val result = df .parse(s, pos).asInstanceOf [BigDecimal ]
95+ val result = decimalFormat .parse(s, pos).asInstanceOf [BigDecimal ]
9696 if (pos.getIndex() != s.length() || pos.getErrorIndex() != - 1 ) {
9797 throw new IllegalArgumentException (" Cannot parse any decimal" );
9898 } else {
You can’t perform that action at this time.
0 commit comments