次のコードでメンバー テーブルを作成できません。check the manual that corresponds to your MySQL server version for the right syntax to use near 'schoolID int NOT NULL FOREIGN KEY REFERENCES schools(schoolID),' at line 1
構文の何が問題になっていますか?
ありがとう!
CREATE TABLE schools (
    schoolID int NOT NULL AUTO_INCREMENT PRIMARY KEY,
    parentID int NOT NULL DEFAULT 0,
    schoolname VARCHAR(199) NOT NULL,  
    active int NOT NULL,
    dateENTERED datetime NOT NULL
);
CREATE TABLE members
(
    memberID int NOT NULL AUTO_INCREMENT PRIMARY KEY,
    schoolID int NOT NULL FOREIGN KEY REFERENCES schools(schoolID),
    active int NOT NULL,
    dateENTERED datetime NOT NULL
);