Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

AND VOTERS NOT LIKE '%" - what does this mean?

Status
Not open for further replies.

NeilBelgium

IS-IT--Management
Joined
Sep 18, 2001
Messages
87
Location
BE
i have a questionnaire application, which someone helped me to develop.
i need to amend so that the person can vote for themselves.
i think this may mean that if the username is the same as the person selected to vote for, then no can do.

the whole line reads:
rsListing.Source = "SELECT U_FIRST + ' ' + U_LAST AS NAME, MGR_DIR FROM HAVE_VOTED, USERS WHERE MGR_DIR = U_ID AND VOTERS NOT LIKE '%" + Replace(rsListing__varUser, "'", "''") + "%'"

am I correct?
thanks, neil
 
What is the VOTERS mean? Is it kind like user id or something, I suggest compare with the user id, "LIKE %" statement will cause some of other record may selected also. ------------------
Freedom is a Right
 
Or are you confused with the SQL:
'%"+Replace(rsListing__varUser,"'","''")+"%'
the '%" "%' will search for 'like' records, not exact matches:
"+Replace(rsListing__varUser,"'","''")+"

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top