Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Other Forums
 MS Access
 Measure query execution time in MS Access

Author  Topic 

katarina07
Starting Member

31 Posts

Posted - 2007-09-25 : 09:36:08
Hi,

what is the best way to get the exact execution time of a query in MS Access database?

I have a MS Access macro running approx. 20 queries consecutively. Is it possible to get a list with execution times of these 20 queries after the macro is finished?

I have local as well as ODBC-linked tables (those are on MS SQL Server) in the database - don't know if it matters.

Thanks
Katarina

jackv
Master Smack Fu Yak Hacker

2179 Posts

Posted - 2007-09-25 : 09:51:40
Are the queries running against SQL Server , if so which version?
One approach you could take is set up a Profiler trace. This application comes with SQL Server and allows you view certain events going on in the DB

Jack Vamvas
--------------------
Search IT jobs from multiple sources- http://www.ITjobfeed.com/SQL
Go to Top of Page

katarina07
Starting Member

31 Posts

Posted - 2007-09-25 : 10:06:29
Hi,

the ODBC linked tables in my MS Access database come from SQL Server (but there are also queries which combine local MS Access and SQL Server tables).
I have the MS SQL Server Management Studio 2005 on my PC (also Profiler as a part of it - is that what you meant?), I use it for my queries in SQL, but I dont know about Server side.

I was hoping to measure this in MS Access directly.

Katarina

PS: this is a MS Access database, I think I didnt say it explicitly, just put the question in the MS Access forum


Go to Top of Page

jackv
Master Smack Fu Yak Hacker

2179 Posts

Posted - 2007-09-25 : 10:22:19
Sorry , I should have responded specifically for MS Access . Some potential approaches are:
1)datediff now() in seconds, putting a marker before and after the query. You would have to use VBA
2)If you need to be more precise , you could use GetTickCount()

Jack Vamvas
--------------------
Search IT jobs from multiple sources- http://www.ITjobfeed.com/SQL
Go to Top of Page

katarina07
Starting Member

31 Posts

Posted - 2007-09-25 : 10:53:53
Thanks
I will do that.
Katarina
Go to Top of Page
   

- Advertisement -