Well, this case is somewhat weird. I have a number of tables like:
PRAGMA "foreign_keys" = 1; CREATE TABLE "foo-L" ( key INTEGER PRIMARY KEY REFERENCES "foo" (key), value INTEGER NOT NULL); Which are tied to a single table, like: CREATE TABLE "foo" ( key INTEGER PRIMARY KEY, value INTEGER NOT NULL); This structure is, obviously, could just as well be represented with, e. g.: CREATE TABLE "foo" ( "key" INTEGER PRIMARY KEY, "value" INTEGER NOT NULL, "value-1" INTEGER, … "value-N" INTEGER); (I. e., by abandoning the NOT NULL constraint from the respective columns.) For which I could then specify an uniqueness constraint: CREATE UNIQUE INDEX "foo-unique" ON "foo" ("value", "value-1", …, "value-N"); Now, I'm somewhat concerned that the table above may get overly sparse at times, which makes me wonder if I could establish an equivalent constraint over the original multi-relation structure, as described above? -- FSF associate member #7257 _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users