这是团体和比赛的两个表格。我想将COMPOSITE FOREIGN KEY参考写到单个主键
from keras import backend as K
K.__dict__["gradients"] = memory_saving_gradients.gradients_memory
这样写外键可以吗?还是我们必须像
那样单独写CREATE TABLE IF NOT EXISTS TEAM
(
team_id integer,
team_name text,
PRIMARY KEY (team_id)
)
CREATE TABLE IF NOT EXISTS MATCH
(
match_id integer,
season_year integer,
team1 integer,
team2 integer,
batted_first integer,
batted_second integer,
venue_name text,
other entries
FOREIGN KEY (team1, team2, batted_first, batted_second)
REFERENCES TEAM(team_id)
)