Hi
I've got some code which loops through all a bunch of queries which are looking at linked tables in my database. For each query it runs this:
I'm getting a 'system, resources exceeded' message after 4 loops through this code.
There are 71 tables and they are hefty - just under 400,000 records each, and each query is looking at another query which looks at the data, so it's a little fiddly, but necessary for me to get all the fields in the way I want. I can provide more details on this, but thought I'd keep this simple for now!
As all the data is linked from other databases, so I don't understand why I'm getting a resources issue? - if it works for 4 loops, I would have thought it should be OK for going through all and exporting all the queries?
Can anyone suggest what I can do differently?
Thanks!
PS I'm using Access 2013
I've got some code which loops through all a bunch of queries which are looking at linked tables in my database. For each query it runs this:
Code:
Sub export_tab_to_csv(mytab As String)
Dim qname As String
Dim exportpath As String
qname = "Export " & mytab
exportpath = "C:\Access Exports\" & mytab & ".csv"
DoCmd.TransferText acExportDelim, , qname, exportpath, True
Debug.Print mytab
DoEvents
End Sub
I'm getting a 'system, resources exceeded' message after 4 loops through this code.
There are 71 tables and they are hefty - just under 400,000 records each, and each query is looking at another query which looks at the data, so it's a little fiddly, but necessary for me to get all the fields in the way I want. I can provide more details on this, but thought I'd keep this simple for now!
As all the data is linked from other databases, so I don't understand why I'm getting a resources issue? - if it works for 4 loops, I would have thought it should be OK for going through all and exporting all the queries?
Can anyone suggest what I can do differently?
Thanks!
PS I'm using Access 2013