xubo245 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_r277189124
##########
File path: core/src/main/java/org/apache/carbondata/core/util/BlockletDataMapUtil.java
##########
@@ -264,6 +264,14 @@ public static boolean isSameColumnAndDifferentDatatypeInSchema(
.equalsIgnoreCase(tableColumnList.get(i).getColumnName()) && !indexFileColumnList.get(j)
.getDataType().getName()
.equalsIgnoreCase(tableColumnList.get(i).getDataType().getName())) {
+ if ("varchar".equalsIgnoreCase(indexFileColumnList.get(j).getDataType().getName()) &&
+ "string".equalsIgnoreCase(tableColumnList.get(i).getDataType().getName())) {
+ LOG.info("Datatype of the Column " + indexFileColumnList.get(j).getDataType().getName()
+ + " present in index file, is varchar and not same as datatype of the column " +
+ "with same name present in table, " +
+ "because carbon convert varchar of carbon to string of spark");
+ return true;
Review comment:
ok,you are right, done
----------------------------------------------------------------
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