> Can I ask what it is that you're trying to do ? This smacks of trying to add > 1 to an existing value or something like that.
Sure. I have a table of items. Each item has a type, a name, and properties A, B, C (and some more, but they're not relevant here). I want to enforce that items of a certain type and name are unique: UNIQUE (type, name). But there can be multiple items with the same name as long as they are of different types. Furthermore, items of a certain type that have identical properties A, B, C are also considered equal, regardless of their name: UNIQUE (type, A, B, C). I cannot use UNIQUE (type, name, A, B, C), as this would mean that there can be two items with the same A, B, C (and type, of course), but different name. On the other hand, there could be two items with the same same (and type, of course) but different A, B, C. Now when inserting an item that already exists (according to the uniqueness definition above), the existing item should be updated with the new name and A, B, C properties. _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users