[Catalyst] Why Can't I Create a Model For Tables With Autoincrement
hkclark at gmail.com
hkclark at gmail.com
Mon Mar 20 05:36:18 CET 2006
If I create an SQLite table using this:
CREATE TABLE user (
id INTEGER PRIMARY KEY AUTOINCREMENT,
username TEXT,
password TEXT
);
Then when I try to create my model I get this:
[MyApp]$ script/myapp_create.pl model DBIC DBIC dbi:SQLite:myapp.db
exists "/test/MyApp/script/../lib/MyApp/Model"
exists "/test/MyApp/script/../t"
exists "/test/MyApp/script/../lib/MyApp/Model/DBIC.pm"
sqlite_sequence has no primary key at
/usr/lib/perl5/site_perl/5.8.5/DBIx/Class/Loader.pm line 110
Segmentation fault
[MyApp]$
But if I remove the AUTOINCREMENT it works fine. I know that SQLite will
still increment the id for me even without the AUTOINCREMENT keyword, but it
seems like it should also work with the keyword.
Thanks,
H
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.rawmode.org/pipermail/catalyst/attachments/20060319/30902913/attachment.htm
More information about the Catalyst
mailing list