Results 1 to 2 of 2
  1. #1
    cgclower is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Jul 2011
    Posts
    6

    problem with my DoCmd.RunSQL statement

    What is wrong with my SQL statement? I'm betting it's something simple, like a quote in the wrong place or something, but I can't figure it out.

    Code:
    DoCmd.RunSQL "UPDATE Table1 SET Table1.Field2='Deleted', WHERE Table1.Field1=" & variable1
    Thank you in advance or the help!

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Try:
    DoCmd.RunSQL "UPDATE Table1 SET Table1.Field2='Deleted', WHERE Table1.Field1='" & variable1 & "'"

Please reply to this thread with any new information or opinions.

Similar Threads

  1. RunSQL String Problem
    By Swarland in forum Programming
    Replies: 3
    Last Post: 12-14-2010, 09:30 AM
  2. my first DoCmd.RunSQL
    By broecher in forum Programming
    Replies: 4
    Last Post: 11-05-2010, 09:35 PM
  3. docmd.runsql update
    By Mitch_Aus in forum Programming
    Replies: 2
    Last Post: 10-05-2010, 09:45 AM
  4. Problem with DoCmd.RunSQL
    By Peter01 in forum Programming
    Replies: 2
    Last Post: 09-10-2009, 07:11 PM
  5. docmd.runsql not working
    By Rameez in forum Programming
    Replies: 3
    Last Post: 08-07-2009, 10:07 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums