mirror of
https://gitlab.com/jrmiller82/pathfinder-2-sqlite.git
synced 2026-10-16 22:29:44 -04:00
Many-to-many table for actions and sourceentry
This commit is contained in:
1 parent
2e5b1dfcaf
commit
72f5d358f5
1 file changed
+10
@@ -36,3 +36,13 @@ CREATE TABLE actions_traits (
|
||||
actions_id INTEGER NOT NULL,
|
||||
traits_id INTEGER NOT NULL
|
||||
);
|
||||
|
||||
-- Joining table --
|
||||
CREATE TABLE actions_sourceentries (
|
||||
id INTEGER PRIMARY KEY
|
||||
,actions_id INTEGER NOT NULL
|
||||
,sourceentry_id INTEGER NOT NULL
|
||||
,UNIQUE (id, actions_id, soruceentry_id),
|
||||
,FOREIGN KEY (actions_id) REFERENCES actions(actions_id)
|
||||
,FOREIGN KEY (sourceentry_id) REFERENCES sourceentry(sourceentry_id)
|
||||
);
|
||||
Reference in new issue
Block a user