I've been talking with Bogdan about a change to SQLite Expert and ran
across something I did NOT expect.
I have this schema:
CREATE TABLE [tApplicationPaths] (
[AppID] INTEGER PRIMARY KEY,
[ApplicationName] CHAR,
[ApplicationMonitorPath] CHAR,
[SearchSubDirs] BOOL DEFAULT 1,
[SearchMask] CHAR DEFAULT AppID);
When I insert a new row, I get the literal string "AppID" as a default
value for that new row. I was expecting a number or null, or something.
Not a string. Is this intended behavior?
Looks like another case where SQLite tries its best to avoid balking at
a statement, just like when it tries to auto-correct single vs double
quotes.
Try using square brakets or double quotes around AppID:
CREATE TABLE [tApplicationPaths] (
[AppID] INTEGER PRIMARY KEY,
[ApplicationName] CHAR,
[ApplicationMonitorPath] CHAR,
[SearchSubDirs] BOOL DEFAULT 1,
[SearchMask] CHAR DEFAULT [AppID]);
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users