In Oracle 11gR2 i have this problem:
I have for example TABLE_A
with structure:
+--------+--------+--------+
| COL1 | COL2 | COL3 |
+--------+--------+--------+
and TABLE_B_
with structure:
+--------+--------+--------+
| COL2 | COL1 | COL3 |
+--------+--------+--------+
(so column definitions are the same but they are in different order)
Executing something like that:
INSERT INTO TABLE_A
SELECT * FROM TABLE_B;
Will work ok?
My problem is that making list of columns will exceed 32767 chars for EXECUTE IMMEDIATE
statement.