Arbol One <arbol...@gmail.com> wrote: > When using the statement 'UNIQUE INTEGER val', does SQLite3 automatically > create a unique integer value for the transaction or would it only > ascertain the uniqueness within that column? > > i.e.: > > Glib::ustring sql_param_tblName = "CREATE TABLE name(n_id INTEGER PRIMARY > KEY, title TEXT, fname TEXT, mname TEXT, lname TEXT)";
Generally, UNIQUE or PRIMARY KEY constraint merely enforces uniqueness, it doesn't automatically generate a unique value for you. However, in SQLite, INTEGER PRIMARY KEY column (when spelled exactly this way) is special: http://sqlite.org/lang_createtable.html#rowid -- Igor Tandetnik _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users