Question, why this dose not work?
create table one (a int(1) default 1, b int(2));
create table two (b int(1));
insert into one select * from two;
error:
Column count doesn't match value count at row 1
a know it, a can count, but why, philosophically?
database knows, what the name of inserting column from table two is b, knows that the column a in table one has a default value equal 1..
so, what problem of executing this query?
And general - How can i do this differently, not manual, without information of a columns and their count, if this way is impossible?
I know this:
table two always have all the same columns, that the table one have. But table one have another columns too, that have a some default values.
Is there some way to do that? insert all data from two in one, and fill the remaining columns by some default or other values!
Need help! Thank you very match!