Solved

Alternate to Contains with fulltext index disabled in SQL Server 2005

Posted on 2006-07-07
2
294 Views
Last Modified: 2006-11-18
Hi All,
I had a small problem with my search Query, i need to do contains search,

when i use like with % its searching the values which are having the given string or more

Ex: If i gave id like '%12345%' , its returning rows which are having 123435+ some extra only , but its not returning the records which are having 123 or so on.
but i need those records also.

I found that we can use CONTAINS but for that FULLTEXT INDEX Should be enabled, but our clent is not ready to enable this due to performance and some other aspects.

So can anybody help out in this search.

Thanks in Advance.

Regards,
Raju P S
0
Comment
Question by:rajups
  • 2
2 Comments
 
LVL 23

Expert Comment

by:Racim BOUDJAKDJI
ID: 17057621
try pattern likes combination
ex:

LIKE '1[0-9][0-9][%]'
0
 
LVL 23

Accepted Solution

by:
Racim BOUDJAKDJI earned 125 total points
ID: 17057626
usage example:

LIKE '123[%]'

Hope this helps...
0

Featured Post

The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When you hear the word proxy, you may become apprehensive. This article will help you to understand Proxy and when it is useful. Let's talk Proxy for SQL Server. (Not in terms of Internet access.) Typically, you'll run into this type of problem w…
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question