+ 1
check problem in sql
i keep getting :3 errors were found during analysis. A comma or a closing bracket was expected. (near "check" at position 87) Unexpected beginning of statement. (near "num_chambre" at position 94) Unrecognized statement type. (near "BETWEEN" at position 106) for this code ; use hotel; CREATE TABLE sejour(num_sej int AUTO_INCREMENT primary KEY,num_chambre int(4) not null check (num_chambre BETWEEN 1 and 1000),date_deb date not null CHECK (date_deb <= now(date)),date_fin date CHECK(date_fin <= now(date) and date_fin> date_deb),num_patient_sej int(10));
1 Answer
0
Which DBMS are you using? there are syntax variations amongst DBMS.