Github user amansinha100 commented on a diff in the pull request: https://github.com/apache/drill/pull/407#discussion_r55557460 --- Diff: exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/union/UnionAllRecordBatch.java --- @@ -162,6 +162,25 @@ private IterOutcome doWork() throws ClassTransformationException, IOException, S allocationVectors = Lists.newArrayList(); transfers.clear(); + // If both sides of Union-All are empty + if(unionAllInput.isBothSideEmpty()) { + for(int i = 0; i < outputFields.size(); ++i) { --- End diff -- If both sides are empty, wouldn't outputFields.size() be 0 ? Or is outputFields populated from a previous batch, which implies both sides may not have been empty. Can you clarify ?
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---