none
Cannot Open Any More Databases RRS feed

  • Question

  • I have a database which I'm working on.  It is composed of split database, both front and multiple links to backend which are in the same folder on my local drive.  It is in development still, so no one else is accessing it. 

    I am working on a report that has 15 sub-reports.  All of the data comes from the same backend.  Each sub-report and the main report have queries as their data source.  Each query is different, except one of the sub-report queries use a common query (or common queries) as one of the sources.  When I run the report, I get the message that is in a loop which outputs "Cannot open any more databases." 

    I'm assuming that access runs all the queries simultaneously which is causing the error when a common query is trying to open a source that is already in-use.  Is there a way to run through each of the sub-report individually?  In other words, run one sub-report at a time then close any of the corresponding queries and then run the next one.  I haven't tried this, but I think I can do a work around which is to get away from doing all the sub reports and just use one report and retrieve all the data that way.  Would this be the only way to fix this?

    Wednesday, October 28, 2015 11:17 PM

Answers

All replies

  • Certainly not the only way. For example, if you're stacking queries to display an aggregate result, you might be able to avoid the error by storing the result in a temp table for further processing. Just a thought...
    Thursday, October 29, 2015 12:30 AM
  • Thanks theDBguy I looked elsewhere and it seems like this is the approach I have to take.  This will not only resolve my issue but it will probably make the performance of my report a lot faster.  Now I just have to man up for the tedious part of making tables for all the 15 queries. 
    Tuesday, November 3, 2015 1:37 AM
  • Good luck. Let us know how it goes...
    Tuesday, November 3, 2015 2:12 AM