relational database design scenario
问题 Consider we have 2 tables like the following: products: id, name (PK = id) product_group1: product_id (PK = a1_id) (FK = a1_id REFRENCES a1) product_group2: product_id (PK = a1_id) (FK = a1_id REFRENCES a1) product_group3: product_id (PK = a1_id) (FK = a1_id REFRENCES a1) the question is , I want to design a table called approved_products that only accepts products from group1 and group2(not group3). how can I design such table ? (I'm using mysql BTW) 回答1: You cannot solve this problem with