If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > ANSI SQL > NOT CONTAINS command

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 12-06-03, 00:16
paras42 paras42 is offline
Registered User
 
Join Date: Dec 2003
Posts: 1
NOT CONTAINS command

I am trying to use the NOT CONTAINS command in SQL to select for
rows that do not contain certain phrases. However, about 95-99% of the rows will actually not contain those phrases, but every now and then, there is a row that contains one or more of the phrases. Anyone have an idea why this might be so. Here is an example of the query that I am using:


select _____ from ______ where
NOT CONTAINS (_____, ' "prior study" or "no prior" or "comparison"
or "yesterday") > 0;

The majority of the resulting rows do not contain any of those words or phrases, but a few do. I am trying to figure out why that is. I even tried changing the syntax to:

select _____ from ______ where
NOT CONTAINS(_____, ' "prior study" ' ) > 0
and NOT CONTAINS ( _____, ' " no prior" ' ) > 0

etc..... where I keep using the NOT CONTAINS in replace of OR. However, I get the same results.

Anyone have any ideas why this might be the case? Any help would be greatly appreciated!!
Reply With Quote
  #2 (permalink)  
Old 12-10-03, 02:41
cvandemaele cvandemaele is offline
Registered User
 
Join Date: Oct 2003
Location: Switzerland
Posts: 140
What database are you using ?
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On