Hi all, I've been lurking for a few days while I explore SQLite and find myself now with a question.
What's the correct usage for the "ON DELETE NO ACTION" statement? I'm converting a schema file to SQLite. Executing a create table statement on the sqlite3 cmd-line, ON DELETE NO ACTION yields an error: SQL error: near "ON": syntax error. Yet according to the docs: "NO ACTION" is a valid action. Is the absence of the ON DELETE rule itself (example 2 below) equivalent to specifying "ON DELETE NO ACTION?" What concept am I missing from the docs? ;) Thanks Scott -- 1) doesn't work CREATE TABLE foo ( foo_id SERIAL PRIMARY KEY, bar_id INTEGER NOT NULL REFERENCES bar(bar_id) ON DELETE NO ACTION, created TIMESTAMP DEFAULT CURRENT_TIMESTAMP); -- 2) works!!! CREATE TABLE foo ( foo_id SERIAL PRIMARY KEY, bar_id INTEGER NOT NULL REFERENCES bar(bar_id), created TIMESTAMP DEFAULT CURRENT_TIMESTAMP); _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users