I'm new to this forum and to MySql so please excuse me if my explanation of the problem lacks anything. Basically, I've created all my Parent tables and now I'm working on the junction tables. I have created one or two junction tables so far that have 2 foreign keys in each table which are also both primary keys in each table. One of the foreign keys I used is called sno_id and it references back to the parent table sno_Table. Now I was able to make sno_id as the foreign key in one of the junction tables by using a constraint (alter table sno_Ref add constraint fk_sno foreign key (sno_id) references sno_Table (sno_id)). However, in this other junction table right now which has 2 primary keys (location_id and sno_id), I was able to make location_id as a foreign key but it won't make sno_id as the foreign key. This time I didn't add the constraint so I made sure there wouldn't be an identical constraint name, and also I know for sure the values in the sno_id column in this table are found in the parent table, sno_Table. The error I get is 1452 - Cannot add or update a child row: a foreign key constraint fails. What do I do?