PDA

View Full Version : Mysql Errore 1064


roip
09-03-2004, 09:27
Sto usando Mysql 4.0.18, seguendo la guida di un manualetto ho dgt il
seguente comando x creeare una tabella


mysql> create table films (
-> film_id int(9) not null auto_increment,
-> genere int(3) not null,
-> titolo varchar(50) not null,
-> anno_prod year,
-> attori varchar(120),
-> distributore int(6) not null unsigned,
-> supporto char(3) not null,
-> prezzo decimal(8,2) not null,
-> noleggio decimal(8,2) not null,
-> giacenza int(6)not null unsigned default '0',
-> primary key (film_id)
-> );

...puntualmene iol sistema mi restituisce questo errore;

ERROR 1064: You have an error in your SQL syntax. Check the manual that
corresp
onds to your MySQL server version for the right syntax to use near
'unsigned,
supporto char(3) not null,



....ho provato e riprovato a riscrivere tutto, ma nulla

io credo si tratti di una incompatibilità forse dei comandi relativa alla versione di mysql...

grazie

Ciao

gerasimone
09-03-2004, 09:46
provato a scrivere
distributore int(6) unsigned not null ?

roip
09-03-2004, 10:42
S, in effetti il prob era quello, cioè della posizione di 'unsigned' rispetto a not null.....


thx very much!