Results 1 to 2 of 2

Thread: SQL and VB

  1. #1
    Join Date
    Apr 2004
    Posts
    13

    Unanswered: SQL and VB

    I have 10 tables in Access.I'm trying to manipulate more than two queries
    on each table to do defferent things.
    the queries do the same operation with all the tables.so I want to write Vb sub with sql to write the code one time of the queries.
    DoCmd.RunSQl is the way but how I can use output of first quiery to the
    next RunSQL
    Best regards...

  2. #2
    Join Date
    Feb 2004
    Location
    CT,USA
    Posts
    250
    Here's an example:

    DoCmd.RunSQL "UPDATE Employees " & _
    "SET Employees.Title = 'Regional Sales Manager' " & _
    "WHERE Employees.Title = 'Sales Manager';"

    What would you need to change for your next query? the TABLE name, some ordering, or something else?

Posting Permissions

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