sqlite-net icon indicating copy to clipboard operation
sqlite-net copied to clipboard

Multi Primary Keys not allowed ?

Open markusalbrecht-procam opened this issue 3 years ago • 2 comments

A question regardin the Table creation as in Standard SQLite it is possible to create tables contining multiple PRIMARY KEYs like e.g.:

CREATE TABLE something ( column1, column2, column3, PRIMARY KEY (column1, column2) );

When doing this via sqlite-net by using classes like this:

image

It always returns an Error: table "TB_TechnicalAttribute" has more than one primary key

Is there a way top achieve this ?

markusalbrecht-procam avatar Feb 18 '22 07:02 markusalbrecht-procam

DB.Execute allows it:

image

but I cannot use the internal models and need to use a string query what I actually try to avoid wherever I can. In case tablemodels get extended later on we always nee to also check the Execute strings.

markusalbrecht-procam avatar Feb 18 '22 08:02 markusalbrecht-procam

looks like its probably not going to happen. Open issue for years. https://github.com/praeclarum/sqlite-net/issues/280

mwa-corey avatar Mar 01 '23 23:03 mwa-corey