I have a table in my database... I want to insert a row to table1 by reading from a record on sqlite_sequence... I know the sqlite_sequence table is for AUTOINCREMENT... and also my table1 has AUTOINCREMENT for _id as well... I tried this:
INSERT INTO table1 (column_1, column_2) VALUES ((SELECT seq FROM sqlite_sequence WHERE name=other_table),`other_column`);
but after inserting, inserted row will be deleted in table1... where is my mistake?? thanks!
Aucun commentaire:
Enregistrer un commentaire