PDA

View Full Version : Hey SQL smart peeps



Sooner in Tampa
12/18/2006, 11:28 AM
How do I do a multiple digit wildcard search with SQL 2000??? Is it even possible? I am pretty sure that it HAS to be on the end...I can't do e**l and return evil...right??

i.e. SEARCH: Soone** would return Sooners.

TIA smart people

dolemitesooner
12/18/2006, 11:32 AM
Check in the services list for "Microsoft Search." If not listed, insert the SQL Server media, and select "Upgrade, Add or Remove Components." Click next for "Add Components." On the next screen, select "Multiple," Full-Text Search, and then continue with the rest of Search.

The wild Card search is easy to multipile

Ash
12/18/2006, 12:07 PM
Searches like that work in the database I'm using. For example, using the WHERE and LIKE with L* for Left, returns all "Left" entries. Same goes for L**t.

SoonerInKCMO
12/18/2006, 12:38 PM
Does - where like 'L%t' - not work for finding Left, Loot, Lot, etc.?

Norm In Norman
12/18/2006, 01:32 PM
Try '?'. for instance, 's??ners' would find 'sooners' but not 'swhattheheckisallthistextdoinginhereners' like 's*ners' would. i dunno if this works in SQL 2000 though. It works in Access, which is also a microsoft product.

Pricetag
12/18/2006, 01:37 PM
Try the underscore character (_). It matches any single character.

Ash
12/18/2006, 01:55 PM
Hey, all you hata's out there. Search this:
**** off, dip ****!

Ash
12/18/2006, 01:56 PM
Try '?'. for instance, 's??ners' would find 'sooners' but not 'swhattheheckisallthistextdoinginhereners' like 's*ners' would. i dunno if this works in SQL 2000 though. It works in Access, which is also a microsoft product.



:D

Sooner in Tampa
12/18/2006, 03:26 PM
The ? does nothing.

As far as using LIKE...we are trying to avoid that due to the large number of records in the database. We are using webservices to run these searches and want to really hum along.

HoserSooner
12/18/2006, 03:29 PM
The only wildcard that I am aware of in SQL (Microsoft version as least) is the % sign. I use it on a daily basis around here, but I can't say how efficient it is.