define foreign keys

This commit is contained in:
yggverse 2024-11-16 15:39:42 +02:00
parent fdc6e739b4
commit 7370815f9d
16 changed files with 59 additions and 26 deletions

View file

@ -82,7 +82,9 @@ pub fn init(tx: &Transaction) -> Result<usize, Error> {
`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
`profile_id` INTEGER NOT NULL,
`time` INTEGER NOT NULL,
`request` TEXT NOT NULL
`request` TEXT NOT NULL,
FOREIGN KEY (`profile_id`) REFERENCES `profile`(`id`)
)",
[],
)