Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

ms access faster query method

Posted on 2012-03-17
4
Medium Priority
?
256 Views
Last Modified: 2012-07-19
I have a query that I am running when a button is clicked.  I am using the DoCmd.Openquery method to run the query.

Is there a method/code that is faster in access to run the query.  I know ther are other ways to sepcify and run a query - wanted to know what my option are.

Here is the query:

INSERT INTO AC_DB2ADMIN_VIEWAECAPHEADER
SELECT DB2ADMIN_VIEWAECAPHEADER.*
FROM DB2ADMIN_VIEWAECAPHEADER;

Thanks for your help.
0
Comment
Question by:johnmadigan
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 75

Accepted Solution

by:
DatabaseMX (Joe Anderson - Microsoft MVP, Access and Data Platform) earned 2000 total points
ID: 37733510
Try just this;

CurrentDB.Execute "YourActionQueryName", dbFailOnError

If you have DoCmd.SetWarnings False   anywhere, Comment that out.

mx
0
 
LVL 46

Expert Comment

by:aikimark
ID: 37733850
I don't see a Where clause.  Do you mean to insert all the DB2ADMIN_VIEWAECAPHEADER rows?
0
 
LVL 44

Expert Comment

by:GRayL
ID: 37735925
Can you explain what you are trying to do with that query - I see taking all the records from a given table and inserting them back into the same table?
0

Featured Post

Get free NFR key for Veeam Availability Suite 9.5

Veeam is happy to provide a free NFR license (1 year, 2 sockets) to all certified IT Pros. The license allows for the non-production use of Veeam Availability Suite v9.5 in your home lab, without any feature limitations. It works for both VMware and Hyper-V environments

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

AutoNumbers should increment automatically, without duplicates.  But sometimes something goes wrong, and the next AutoNumber value is a duplicate.  This article shows how to recover from this problem.
Did you know that more than 4 billion data records have been recorded as lost or stolen since 2013? It was a staggering number brought to our attention during last week’s ManageEngine webinar, where attendees received a comprehensive look at the ma…
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question