Current environment:
SQL Server 6.5 (SP3) on NT 4.0 (sp3)
I have a database with a column called FAC_NAME that I want to be able
to do fast CONTAIN (LIKE) searches on. Assume the column/field is
indexed.
If I do an equality type search on this column I get extremely fast
results.
If I do a Begins With LIKE, such as FAC_NAME LIKE 'SMITH%' I also
get fast results.
But if if do a Contains LIKE, such as FAC_NAME LIKE '%SMITH%' the
search takes forever.
The table has 450,000 records. The Equality test obviously uses the
indexes to find the records, and it appears that the Begins With also
uses the indexes, but the Contains evidently just searches the column
without use of the indexes.
I tried making a separate table of the FAC_NAME and key field, and the
CONTAINS search takes about 1/2 the time, but is still slow.
Is there a way to get fast CONTAIN type searches. Does SQL Server 7.0
provide faster searches with CONTAIN type searches?
Any help or info would be greatly appreciated.
Russ
Calif. Dept. of Toxic Substances Control