I think you have to specify a key length when you use an index on a text field...

mysql> alter table t2 add index i2(t1(3));

That would create an index (called "i2") on the first 3 characters of field "t1" of table "t2".

I think that's right?

Douglas Sims
[EMAIL PROTECTED]



On Sep 27, 2006, at 8:53 PM, Peter Van Dijck wrote:

Hi,
since urls can be longer than 255 chars, I made the url field a TEXT field.

The problem is, I can't make an index on it, so doing 'WHERE
url='xxx'' becomes a very sloow query.

Any ideas for solutions? Am I mistaken in the idea that I can't make
an index on a TEXT field?

Thanks!
Peter

--
Find 10000s of videoblogs and podcasts at http://mefeedia.com
my blog: http://poorbuthappy.com/ease/
my job: http://petervandijck.net

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to