resetDictionary right after get dictionary page
resetDictionary in reset() cleaned dictionary regardless of the fact
that dictionary page is null or not. resetDictionary should happen
only after get dictionary page and the page is not null.
@@ -281,6 +281,8 @@ public class PrimitiveColumnWriter
dictPage.add(pageData);
totalCompressedSize += pageHeader.size() + compressedSize;
totalUnCompressedSize += pageHeader.size() + uncompressedSize;
+
+ primitiveValueWriter.resetDictionary();
}
getDataStreamsCalled = true;
@@ -308,9 +310,6 @@ public class PrimitiveColumnWriter
@Override
public void reset()
{
- primitiveValueWriter.reset();
- primitiveValueWriter.resetDictionary();
-
pageBuffer.clear();
closed = false;
