MySQL “Foreign key constraint is incorretly formed”
问题 I am having trouble with this code. CREATE TABLE Reservation ( Movie_Title varchar(255) NOT NULL, Theatre_No int NOT NULL, Complex_Name varchar(255) NOT NULL, Start_Time datetime NOT NULL, CustomerID int NOT NULL, Number_of_Tickets int NOT NULL, PRIMARY KEY (Movie_Title, Theatre_No, Complex_Name, Start_Time, CustomerID), FOREIGN KEY (Movie_Title) REFERENCES Showings(Movie_Title), FOREIGN KEY (Theatre_No) REFERENCES Showings(Theatre_No), FOREIGN KEY (Complex_Name) REFERENCES Showings(Complex