Subject Re: [firebird-support] UNIQUE string length
Author Doug Chamberlin
At 10/31/2003 09:30 AM (Friday), Lester Caine wrote:
>[In converting from en existing MySQL database] There are several
>VARCHAR(255)
>strings with a UNIQUE key set. I SHOULD be able to do that
>with a simple ascii string - shouldn't I? It complains that
>the key is too long - so what am I missing, I thought that
>255 characters was OK. If not, how do I get round this?

I think the real limit for an index/key is 255 bytes minus a few for
overhead. Try VARCHAR(250) instead of VARCHAR(255) and see if it works.
Should be exact numbers in the release notes I think.

You could check the existing database to see if any records actually have
more than 250 chars in them. If not, the VARCHAR(250) limit should not
present a big future problem, eh?