Log in Register FAQ Memberlist Search ContactReview Forum Index
A GoldMine Discussion and Support Community

ContactReview Forum Index » GoldBox » Not Like SQL Statement
Post new topic  Reply to topic View previous topic :: View next topic 
Not Like SQL Statement
PostPosted: Fri Nov 04, 2011 6:56 am Points: 0 Reply with quote
tt
GoldMine Apprentice
Joined: 18 Jan 2007
Posts: 23




I'm trying to figure out if if I can accomplish the following in a sql query for a "Replace History" function.

I have a current sql statement that reads as follows and which works perfectly:

CONTHIST.RECTYPE = 'L' AND CONTHIST.ACTVCODE ='FOR' AND CONTHIST.REF LIKE 'BML00%' AND ( CONTACT1.CONTACT ='' OR CONTACT1.CONTACT IS NULL)

I am trying to add an additional condition to the above statement that would select history records where the reference field of the activity does not contain the record's company name in it. I have tried appending the 2 following statements to the above statement but neither of them work.

AND CONTHIST.REF NOT LIKE %CONTACT1.COMPANY%

AND CONTHIST.REF NOT LIKE '%CONTACT1.COMPANY%'
View user's profile Send private message

Not Like SQL Statement
  ContactReview Forum Index » GoldBox
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 7 Hours  
Page 1 of 1  

  
  
 Post new topic  Reply to topic  


Brought to you by Castell Computers, Doug Castell, Admin
RSS Feed
Powered by phpBB © 2001-2004 phpBB Group
Theme created by Vjacheslav Trushkin