[GitHub] [carbondata] ajantha-bhat commented on a change in pull request #3181: [CARBONDATA-3356] Fix the issue when carbonData DataSource read SDK files with varchar

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[GitHub] [carbondata] ajantha-bhat commented on a change in pull request #3181: [CARBONDATA-3356] Fix the issue when carbonData DataSource read SDK files with varchar

GitBox
ajantha-bhat commented on a change in pull request #3181: [CARBONDATA-3356] Fix the issue when carbonData DataSource read SDK files with varchar
URL: https://github.com/apache/carbondata/pull/3181#discussion_r277220940
 
 

 ##########
 File path: store/sdk/src/main/java/org/apache/carbondata/sdk/file/Field.java
 ##########
 @@ -78,6 +78,8 @@ public Field(String name, String type) {
       this.type = DataTypes.FLOAT;
     } else if (type.equalsIgnoreCase("double")) {
       this.type = DataTypes.DOUBLE;
+    } else if (type.equalsIgnoreCase("decimal")) {
+      this.type = DataTypes.createDefaultDecimalType();
 
 Review comment:
   Also creating Default is not a good idea, user might want to set scale and precision. That's why this constructor was not added.
   Refer `testAllPrimitiveDataType` testcase where decimal is called with other Field constructor

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[hidden email]


With regards,
Apache Git Services