Add ON DELETE CASCADE for future sqlite databases too
This commit is contained in:
parent
33148909d6
commit
6cda7ab549
@ -63,7 +63,7 @@ func init() {
|
|||||||
content %[1]s NOT NULL,
|
content %[1]s NOT NULL,
|
||||||
|
|
||||||
PRIMARY KEY (chat_jid, chat_receiver, jid),
|
PRIMARY KEY (chat_jid, chat_receiver, jid),
|
||||||
FOREIGN KEY (chat_jid, chat_receiver) REFERENCES portal(jid, receiver)
|
FOREIGN KEY (chat_jid, chat_receiver) REFERENCES portal(jid, receiver) ON DELETE CASCADE
|
||||||
)`, byteType))
|
)`, byteType))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
Loading…
Reference in New Issue
Block a user