INSERT x WITH AUTO NAME SELECT * FROM y should not fail on "Column 'z' not found" when y.z exists but not x.z. Sometimes it is necessary to create tables that contain a subset or superset of the columns from another table. An example of a subset might be a temporary table containing only primary keys. An example of a superset might be an audit table that has a different, additional column as primary key, plus other columns for auditing purposes. It is also sometimes convenient to make use of INSERT WITH AUTO NAME together with SELECT * when copying from one table to another. This works fine when the target is a superset, but not when it is a subset. IMO columns in the SELECT that do not exist in the target table should be ignored... after all, that's what WITH AUTO NAME is for, and it already ignores the inverse: columns in the target table which are not specified in the SELECT. CREATE TABLE x ( a INTEGER, b INTEGER ); CREATE TABLE y ( a INTEGER, b INTEGER, z INTEGER ); INSERT y VALUES ( 1, 2, 3 ); COMMIT; -- This fails... INSERT x WITH AUTO NAME SELECT * FROM y; Could not execute statement. Column 'z' not found SQLCODE=-143, ODBC 3 State="42S22" Line 1, column 1 -- This works... INSERT x WITH AUTO NAME SELECT a, b FROM y; SELECT * FROM x; a,b 1,2 -- This also works... INSERT x WITH AUTO NAME SELECT b FROM y; SELECT * FROM x; a,b 1,2 (NULL),2 |