You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 13, 2020. It is now read-only.
I was wondering if there was a way to use a composite Primary Key when using db.createTable to create a table. When reading through the wiki and issues, I couldn't find one. I was hoping to find something in the style of the FOREIGN_KEY() implementation as seen in #258 .
The expected behaviour would be
db.createTable(
ActivityEntry.TABLE_NAME,
true,
ActivityEntry.COLUMN_USER_ID to INTEGER+NOT_NULL,
ActivityEntry.COLUMN_ACTIVITY_NAME to TEXT+NOT_NULL,
PRIMARY_KEY(ActivityEntry.COLUMN_USER_ID,ActivityEntry.COLUMN_ACTIVITY_NAME),
FOREIGN_KEY(ActivityEntry.COLUMN_USER_ID,UserEntry.TABLE_NAME,UserEntry.COLUMN_ID))
The text was updated successfully, but these errors were encountered:
I was wondering if there was a way to use a composite Primary Key when using
db.createTable
to create a table. When reading through the wiki and issues, I couldn't find one. I was hoping to find something in the style of theFOREIGN_KEY()
implementation as seen in #258 .The expected behaviour would be
The text was updated successfully, but these errors were encountered: