Double quotes in Access command strings

Results 1 to 3 of 3

Thread: Double quotes in Access command strings

  1. #1
    Bill Logan Guest

    Default Double quotes in Access command strings

    Hi<BR>does anyone know how to put, for example,<BR>SELECT * FROM X WHERE Y="BOB*",<BR>into a string for an ADODB call. The problem is that the double quote means the end of a string in VBScript. <BR>Thanks

  2. #2
    Join Date
    Dec 1969
    Posts
    168

    Default RE: Double quotes in Access command strings

    I have used the following:<BR>SQLqry="Select * from X where y=&#039bob*&#039;"<BR><BR>but this might work also:<BR>SQLqry="Select * from X where y=""bob*"";"

  3. #3
    Shawn Clabough Guest

    Default RE: Double quotes in Access command strings

    I have always used the following to make sure things stay straight:<BR><BR>strDQ = chr(34)<BR>sql = "SELECT * FROM X WHERE Y=" & strDQ & "BOB*" & strDQ<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •