MySQL Forums
Forum List  »  Microsoft SQL Server

Problem with primary key with size>256
Posted by: Minh Nguyen
Date: November 08, 2004 01:53AM

Hi all,
I have a table in SQL Server with a primary key type varchar(512). When I created that table in MySQL the key is converted to TEXT, but I can't not set it as primary key.

mysql> create table abcd(Pkey varchar(512) not null, primary key(Pkey));
ERROR 1170 (42000): BLOB/TEXT column 'Pkey' used in key specification without a
key length

Please help me how to create a table with primary key has size > 256 ?

Thanks,

Options: ReplyQuote


Subject
Written By
Posted
Problem with primary key with size>256
November 08, 2004 01:53AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.