Subject Re: [ib-support] How to optimize LIKE criteria
Author Helen Borrie
At 04:18 AM 21-12-02 +0000, you wrote:
>Dear all,
>
>My customer need to query a electronics component database using part
>numbers.
>
>For example, if he key in KM16550, he should get records for KM16550,
>KM16550N, KM16550A and KM16550AFN. To do this, it seems I must use a
>LIKE statement "...where PartNo like :PartNo"
>
>I know MySQL can use index in this case. but IB/FB cannot. If the
>size of the db is about 100MB, will that query be very slow? Is there
>other methods to overcome this?

Use STARTING WITH 'KM16550' to have IB use the index.

heLen