|
-
Jul 13th, 2012, 03:03 PM
#1
Thread Starter
Hyperactive Member
SQL issue with access
i have the following. text4 is string i dont wont it to have and text2 and text3 i do want to have but text4 is showing up?
rs.Open "Select * From KnowledgeBase WHERE (Subject not LIKE '%" & Text4 & "%' OR AddDate not LIKE '%" & Text4 & "%' OR Category not LIKE '%" & Text4 & "%' OR Knowledge not LIKE '%" & Text4 & "%')" & _
" AND (Subject LIKE '%" & Text2 & "%' OR AddDate LIKE '%" & Text2 & "%' OR Category LIKE '%" & Text2 & "%' OR Knowledge LIKE '%" & Text2 & "%')" & _
" AND (Subject LIKE '%" & Text3 & "%' OR AddDate LIKE '%" & Text3 & "%' OR Category LIKE '%" & Text3 & "%' OR Knowledge LIKE '%" & Text3 & "%')" & _
" ORDER by Subject", conntemp, adOpenForwardOnly, adLockReadOnly
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|