kumarvishal09 commented on a change in pull request #3887:
URL: https://github.com/apache/carbondata/pull/3887#discussion_r479656884



##########
File path: 
core/src/main/java/org/apache/carbondata/core/metadata/datatype/DecimalConverterFactory.java
##########
@@ -187,6 +197,43 @@ public void fillVector(Object valuesToBeConverted, int 
size,
             vector.putDecimal(i, value, precision);
           }
         }
+      } else if (pageType == DataTypes.BYTE_ARRAY) {
+        // complex primitive decimal dimension
+        int offset = 0;
+        for (int j = 0; j < size; j++) {
+          // here decimal data will be Length[4 byte], scale[1 byte], 
value[Length byte]
+          int len = ByteBuffer.wrap(data, offset, 
DataTypes.INT.getSizeInBytes()).getInt();
+          offset += DataTypes.INT.getSizeInBytes();

Review comment:
       DataTypes.INT.getSizeInBytes), It’s better to assign to some variable 
and use it inside loop, instead calling method every time 




----------------------------------------------------------------
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:
us...@infra.apache.org


Reply via email to