dbTalk Databases Forums  

Data-Checking step not working?

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Data-Checking step not working? in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
roy.anderson@gmail.com
 
Posts: n/a

Default Data-Checking step not working? - 01-05-2005 , 12:33 PM






Hey all,
prolly a simple solution, but why isn't the following string working in
my execute sql step?

select x from new_files where x like '%[^0-9]%' and x like '%[^a-z]%'

Actually, it does work, however, it's displaying all the records? It
should only be displaying those records that do *not* contain letters
or numbers.

Thanks in advance!
-Roy


Reply With Quote
  #2  
Old   
The Margolins
 
Posts: n/a

Default Re: Data-Checking step not working? - 01-09-2005 , 01:29 PM






Roy,

It is impossible to tell without seeing DDL and data sampling.

Ilya

<roy.anderson (AT) gmail (DOT) com> wrote

Quote:
Hey all,
prolly a simple solution, but why isn't the following string working in
my execute sql step?

select x from new_files where x like '%[^0-9]%' and x like '%[^a-z]%'

Actually, it does work, however, it's displaying all the records? It
should only be displaying those records that do *not* contain letters
or numbers.

Thanks in advance!
-Roy




Reply With Quote
  #3  
Old   
Cagey
 
Posts: n/a

Default Re: Data-Checking step not working? - 01-12-2005 , 12:04 PM




Problem is, it will bring back all records with spaces using original
logic.

select * from new_files
where x not like '%[A-Z]%'
and x not like '%[0-9]%'

will stop any records appearing where there are not letters or
numbers.

What are you actually looking for in the anomolies from your query?

IMHO, it may be that the question you're asking isn't strict enough. I
usually find that once the actual question is defined the coding is
relatively simple.



roy.anderson (AT) gmail (DOT) com wrote:
Quote:
Hey all,
prolly a simple solution, but why isn't the following string working in
my execute sql step?

select x from new_files where x like '%[^0-9]%' and x like '%[^a-z]%'

Actually, it does work, however, it's displaying all the records? It
should only be displaying those records that do *not* contain letters
or numbers.

Thanks in advance!
-Roy


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.