mardi 28 juillet 2015

WinRT - Using foreign keys on a windows project with Sqlite

I have this Json that i get from a webservice

[
{
"_id":"55ae4c736fa50b3b21544de4",
"name":"Lunch",
"meetingType":"Business meeting",
"description":"this is the description",
"organization":"54d8766f44caed8c7c9fff48",
"startDate":1437572460000,
"endDate":1437651900000,
"organizer":"54d8766f44caed8c7c9fff4b",
"alternativeOrganizer":"54e5e03a54407e7175092f93",
"__v":6,
"isShortNotice":false,
"meetingStatus":"draft",
"invitees":[
{
"user":"54e30da9685519f659866b61",
"_id":"55ae4c836fa50b3b21544de7",
"status":"accepted"
},
{
"user":"559cece8460d4885255844b4",
"_id":"55ae4c836fa50b3b21544de6",
"status":"pending"
},
{
"user":"54d8766f44caed8c7c9fff4e",
"_id":"55ae4c836fa50b3b21544de5",
"status":"pending"
}
]
}
]

I have a database in sqlite that has 2 tables, Meetings and Invitees, and in my windows store app project im able to fill both of them , but i dont know how to create a "relationship" between them so that i know to wich meeting a invitee belongs too. Im using SQLite for Windows Runtime version 3.8.10.2

Aucun commentaire:

Enregistrer un commentaire