Welcome to the dBforums forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions, articles and access our other FREE features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload your own photos and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact support.

If you prefer not to see double-underlined words and corresponding ads, place your cursor
here for ContentLink opt out.

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, 01: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, 03: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

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