rdblue commented on a change in pull request #1353:
URL: https://github.com/apache/iceberg/pull/1353#discussion_r482615038



##########
File path: core/src/main/java/org/apache/iceberg/TableScanContext.java
##########
@@ -107,16 +112,27 @@ boolean returnColumnStats() {
 
   TableScanContext shouldReturnColumnStats(boolean returnColumnStats) {
     return new TableScanContext(snapshotId, rowFilter, ignoreResiduals,
-        caseSensitive, returnColumnStats, selectedColumns, options, 
fromSnapshotId, toSnapshotId);
+        caseSensitive, returnColumnStats, projectedSchema, selectedColumns, 
options, fromSnapshotId, toSnapshotId);
   }
 
   Collection<String> selectedColumns() {
     return selectedColumns;
   }
 
   TableScanContext selectColumns(Collection<String> columns) {
+    Preconditions.checkState(projectedSchema == null, "Cannot selected columns 
when project schema is specified.");
     return new TableScanContext(snapshotId, rowFilter, ignoreResiduals,
-        caseSensitive, colStats, columns, options, fromSnapshotId, 
toSnapshotId);
+        caseSensitive, colStats, null, columns, options, fromSnapshotId, 
toSnapshotId);
+  }
+
+  Schema projectedSchema() {
+    return projectedSchema;
+  }
+
+  TableScanContext project(Schema schema) {
+    Preconditions.checkState(selectedColumns == null, "Cannot project schema 
when selected columns is specified.");

Review comment:
       How about `Cannot set projection schema when columns are selected`




----------------------------------------------------------------
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:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to