开发者

No such table SQLITE_SEQUENCE from AIR/Actionscript

I'm try开发者_Python百科ing to reset the seed for an autoincrement field in SQLITE using AIR/ActionScript/Flex 4.5.

I'm doing what should normally work:

DELETE FROM SQLITE_SEQUENCE WHERE NAME = 'myTable'

I've checked that the database actually contains a SQLITE_SEQUENCE table. I'm able to execute the above statement without errors directly via the Firefox SQLITE plugin (SQLite Manager).

However, when I try to do the same using actionscript, I get an error:

No such table 'SQLITE_SEQUENCE'.

All I could find in searching around was this one guy who posted everywhere he could find - only to be left without an answer: here and here and here

Any ideas?


sqlite_sequence table is not created, until you define at least one autoincrement and primary key column in your schema.


You should to insert "Auto increment" to primary key column at least to one table, Then SQLite is creating "SQLITE_SEQUENCE" table.

To get all tables have Auto increment:

SELECT * FROM SQLITE_SEQUENCE;
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜