Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error when adding index to 2 fields

Status
Not open for further replies.

youradds

Programmer
Jun 27, 2001
817
0
0
GB
Hi,

I'm trying to setup a new index in a table ... but I'm getting an error:

ALTER TABLE `Clients_Per_Destination` ADD INDEX `c_n_c_n` ( `continent_name_flat` , `country_name_flat` )

MySQL said: Documentation
#1071 - Specified key was too long; max key length is 1000 bytes

At first I thought it was due to the name being too long (the index name), but I've shrunk it to only 7 charachters, and I still get the same error. I also checked the format of those 2 fields, and they are both CHAR(255) .. so I'm at a but of a loss as to where that error is coming from :/

Anyone got any ideas?

TIA

Andy
 
Ah ok - thanks for the reply :)

Cheers

Andy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top