Github user paul-rogers commented on a diff in the pull request:

    https://github.com/apache/drill/pull/939#discussion_r138687170
  
    --- Diff: 
exec/java-exec/src/main/java/org/apache/drill/exec/store/easy/text/compliant/FieldVarCharOutput.java
 ---
    @@ -211,10 +210,10 @@ public void finishRecord() {
           endField();
         }
     
    -    // Fill in null (really empty) values.
    +    // Fill in null values
     
         for (int i = 0; i < nullCols.length; i++) {
    -      vectors[nullCols[i]].getMutator().setSafe(recordCount, nullValue, 0, 
0);
    +      vectors[nullCols[i]].getMutator().setNull(recordCount);
    --- End diff --
    
    Here we are combining null columns and data columns into a single array. 
Perhaps we should have an array of projected columns (non-null), and a separate 
array of null columns (optional varChar).
    
    Note that "memory fragmentation" project has fixed this in the general 
case. In that solution, the solution is similar to that described above: 
projected columns are required, missing columns are nullable.


---

Reply via email to