Relational SQLite on Windows RT -


i using sqlite windows runtime dont see way define relationships between tables. feature supported in sqlite winrt?

if not, there alternative solutions relational local database windows rt?

the database engine supports relationships. 1 way specify foreign keys when creating tables:

create table foo( id integer primary key autoincrement not null , ... )  create table bar( id integer primary key autoincrement not null, fooid integer not null references foo (id) on update cascade, ... ) 

i believe each db connection has enable foreign keys executing following pragma:

pragma foreign_keys = on 

in terms of available orms, guess depends. have used sqlite-net, can speak that. far know, foreign keys not supported feature sql-net. have manually manage relationships.

for example, lets foo object has reference in bar object.

for creating tables, cannot use sqlite-net table creation methods. have use sql create tables along relationships.

also, when use sql-net load foo object, related bar object not automatically loaded. need make second sql-net call load bar object.


Comments

Popular posts from this blog

php - mySql Join with 4 tables -

css - Text drops down with smaller window -

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -