android - Moving all values from table1 to table2( with 1 new column) -
am copying alll values table1 table2.
note : in table2 have added 1 column @ last position.
table1 has 16 columns
table2 has 17 columns.
i used following query :
string s = "insert customer_profile_details select * customer_profile"; db.execsql(s);
it throws exception :
03-11 06:34:46.383: e/copy table(24750): failed copy table android.database.sqlite.sqliteexception: table customer_profile_details has 17 columns 16 values supplied (code 1): , while compiling: insert customer_profile_details select * customer_profile
how solve this, need pass empty value new column.
thanks in advance !
try this:
string s = "insert customer_profile_details select cp.*, null customer_profile cp"; db.execsql(s);
Comments
Post a Comment