Github user sounakr commented on a diff in the pull request:
https://github.com/apache/carbondata/pull/2347#discussion_r191396937
--- Diff:
processing/src/main/java/org/apache/carbondata/processing/datatypes/PrimitiveDataType.java
---
@@ -316,15 +321,32 @@ public int getSurrogateIndex() {
if (!this.carbonDimension.getUseActualData()) {
byte[] value = null;
if (isDirectDictionary) {
- int surrogateKey =
dictionaryGenerator.getOrGenerateKey(parsedValue);
+ int surrogateKey;
+ if (dictionaryGenerator instanceof DirectDictionary
--- End diff --
Rectify the indentation
---