¿Qué tiene de malo esta consulta mysql?
Esto funciona
CREATE TABLE shoutbox_shout (
shout_id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
user_id INT UNSIGNED NOT NULL DEFAULT 0,
shout_date INT UNSIGNED NOT NULL DEFAULT 0,
message MEDIUMTEXT NOT NULL,
KEY shout_date (shout_date)
)
...mientras esto
CREATE TABLE shoutbox_shout (
shout_id INT UNSIGNED NOT NULL AUTO_INCREMENT,
user_id INT UNSIGNED NOT NULL DEFAULT 0,
shout_date INT UNSIGNED NOT NULL DEFAULT 0,
message MEDIUMTEXT NOT NULL,
KEY shout_date (shout_date)
)
... resulta en:
Código de error: 1075 - Definición de tabla incorrecta; solo puede haber una columna automática y debe definirse como una clave
Agregué la clave principal pero aún recibo un error.