MySQL Forums
Forum List  »  Optimizer & Parser

Re: does MySQL support function index?
Posted by: KimSeong Loh
Date: September 21, 2006 10:14PM

No function index in MySQL, but you can index the prefix of a string data type.

Using your example, the following will create the index based on the 1st 2 characters of column TYPE_CODE, assuming it is a string type.
CREATE INDEX I_TYPE_CODE_LAYER1 ON EQ_EQUIP(TYPE_CODE(2));

Options: ReplyQuote


Subject
Views
Written By
Posted
4920
September 21, 2006 06:56PM
Re: does MySQL support function index?
4853
September 21, 2006 10:14PM


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.