Run "make table" query from Excel

scotty2000

New Member
Joined
Feb 26, 2010
Messages
10
This one is starting to get me down!

I've got a background Access database with an Excel front end report.

I run a "make table" query in my Access database to make sure I have the most up to date information from our data warehouse.

I then run a couple of other "select" queries from that table that are linked to my excel front end.

When I refresh the data in Excel, it runs my select queries with no problem, however I need to run the "make table" query first.
I know I could change the "make table" to a "select" query but it means that each time I run my other select queries it has to get the data again from the data warehouse which takes ages.

I'd like to do this without having to open the database and have tried all sorts.

I'm using Excel 2003 and Access 2000

Any ideas?
 
hey xenou
I tried your code and substitute my database location but gives me an error 7866:
Microsoft office Access can't open the database because it is missing, or opened exclusively by another user.
Where as it is actually in the location and nobody is using it.

Can you tel me the solution please
Thanks
 
Upvote 0

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
Not sure. Make sure there is no lock file and try again. If you have put this code into some larger project it could be a conflict with some other code you are running. I personally don't use make-table queries very often. My preferences would be to have a permanent table that is cleared of data and reloaded (run a delete query and an append query, rather than a make-table query).
 
Upvote 0

Forum statistics

Threads
1,225,150
Messages
6,183,196
Members
453,151
Latest member
Lizamaison

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top