Results 1 to 4 of 4
  1. #1
    MrJones1 is offline Novice
    Windows 10 Office 365
    Join Date
    Jan 2022
    Posts
    3

    Deleting a pass-through query - Access runs the query during the delete?

    I have an Access application that generates and runs a lot of ODBC pass-through queries.

    These queries accumulate in the application, and I periodically delete them. When I delete them, Access is running these pass-through queries. WTF? The queries are not open when I delete them, they are closed.



    I've verified these queries are being run on the DB2 host when I delete them in Access.

    For read only queries, this is not a huge problem. For update queries, this is a major problem. I don't want update queries running twice at points in time I don't expect.

    Any idea how to get Access to stop running pass-through queries when I delete them?

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    are you using: currentdb.Querydefs.delete "qsMyPassThruQry"

  3. #3
    MrJones1 is offline Novice
    Windows 10 Office 365
    Join Date
    Jan 2022
    Posts
    3
    No. I'm just manually deleting them through the built-in Access user interface.

  4. #4
    MrJones1 is offline Novice
    Windows 10 Office 365
    Join Date
    Jan 2022
    Posts
    3
    Did more experimentation. Apparently, if I perform a "Cut" of the query from the Custom or Object Type navigation pane, it runs the query as part of the "Cut" operation.

    If I switch to the Object Type navigation pane, and perform a "Delete", it does not run the query during the delete.

    So, solution found, but it doesn't make sense to me that a "Cut" of a query would run a pass-through query.

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

Similar Threads

  1. Replies: 9
    Last Post: 11-29-2017, 10:27 AM
  2. Replies: 10
    Last Post: 05-25-2017, 02:17 PM
  3. Replies: 3
    Last Post: 07-27-2011, 02:07 PM
  4. Delete Query Deleting Too Much
    By TundraMonkey in forum Queries
    Replies: 6
    Last Post: 06-30-2009, 02:39 PM
  5. Delete query, deleting customers froma table.
    By keithsrobinson in forum Queries
    Replies: 2
    Last Post: 02-14-2006, 11:33 AM

Tags for this Thread

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