Fr4nc3sc0NL
Fr4nc3sc0NL

Reputation: 585

Can't add column

I tried to change to name of an existing column, but got MySQL error 1064.

So I then dropped the column to re-ad it with the new name, but got the same error... I'm starting to worry it's something with the db itself since I can't find any error in the phpmyadmin generated query:

ALTER TABLE `Schools` 
ADD `SchoolName` VARCHAR(65) CHARSET=latin1 COLLATE latin1_swedish_ci NOT NULL
AFTER `SchoolId`;

Does anyone know what's going on?

Upvotes: 0

Views: 1754

Answers (2)

starko
starko

Reputation: 1149

ALTER TABLE  `Schools` ADD  `SchoolName` VARCHAR( 65 ) COLLATE latin1_swedish_ci NOT NULL AFTER  `SchoolId`

and next

ALTER TABLE Schools CONVERT TO CHARACTER SET latin1

Upvotes: 0

Ewald
Ewald

Reputation: 5761

I believe this is your problem :

CHARSET=latin1

Remove the "=" sign.

Upvotes: 1

Related Questions