RussellSpitzer commented on issue #2040: URL: https://github.com/apache/iceberg/issues/2040#issuecomment-850016880
I'm not sure why the INSERT INTO behavior has changed, but from what I know the command by default only uses positional information not name resolution when doing inserts. My assumption is that it assumes that since no columns were specified, the insert will be looking for 3 input columns to match the 3 columns in the target. I am pretty sure that to do an insert of specific columns it is supposed to be ```sql INSERT INTO TABLE table (col1, col2) (SELECT dataForCo1, dataForCol2 FROM otherTable) ``` Which i believe is the Hive syntax for this sort of thing. Programmatically the "writeTo(table)" api should do automatic name resolution and not have the same issues as the "INSERT INTO" sql command. -- 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]
