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 |
|
funk.phenomena
Posting Yak Master
121 Posts |
Posted - 2012-02-21 : 12:18:33
|
| Hi All - I have the following table:[CODE]MODELASUS_P101ACER_X5ACER_43497MX_GT26103597799359784946359797746GIGABYTE_MXGTX7[/CODE]I need run a query that excludes based on two conditions (AND):(A) Entirely Numeric AND (B) Length >= 6 charactersOutput would be as follows:[CODE]ASUS_P101ACER_X5ACER_43497MX_GT2610GIGABYTE_MXGTX7[/CODE]Can you help me out:[CODE]SELECT MODEL FROM TABLE1 WHERE LEN(MODEL) >=6 AND MODEL NOT LIKE ?????[/CODE] |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2012-02-21 : 13:46:59
|
| [code]SELECT MODEL FROM TABLE1 WHERE LEN(MODEL) >=6 AND MODEL LIKE '%[^0-9]%'[/code]------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
|
|
|