Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
SamC
White Water Yakist
3467 Posts |
Posted - 2010-11-24 : 10:39:46
|
Is there a wildcard syntax that will search for strings that don't contain the two-letter sequence "FO"? |
|
nigelrivett
Master Smack Fu Yak Hacker
3385 Posts |
Posted - 2010-11-24 : 10:42:55
|
where col not like '%FO%'You can also dolike '%[^A-Z]%'that will return everything with at least one character not between A and Z - i.e not a capital letter.==========================================Cursors are useful if you don't know sql.SSIS can be used in a similar way.Beer is not cold and it isn't fizzy. |
 |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2010-11-24 : 10:44:37
|
you can also use PATINDEX('%FO%',col) = 0if col doesnt contain index------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
X002548
Not Just a Number
15586 Posts |
|
X002548
Not Just a Number
15586 Posts |
|
SamC
White Water Yakist
3467 Posts |
Posted - 2010-11-29 : 09:41:35
|
Argh! The SQL is fixed as:WHERE Column LIKE Parameterwhere Parameter can be specified by the end user as any of the allowed LIKE arguments. This will need development to support NOT LIKE Parameter...Sam |
 |
|
|
|
|