Hi.
I am working on an php application that reads a Microsoft Access database (because I'm pulling data from a 3rd party application and unfortunately they use Microsoft Access). My application opens multiple databases and therefore, makes multiple connections, but after the 65th connection it displays the error:

Warning: odbc_connect() [function.odbc-connect]: SQL error: [Microsoft][ODBC Microsoft Access Driver] Too many client tasks., SQL state 08004 in SQLConnect

I am closing each connection with odbc_close() and odbc_free_result() after each query but it does not close the connection, as far as the server is concerned, the connection stays open.
Any help please? I'll be making more applications like this and i really need a way around it.

Thanks in advance!!!

    You have the code to close and free the results, but are you sure you're executing that code? Double check that there isn't some way the script gets past those statements without running them.

    Do you have connection pooling set up with your web server? It might not be releasing the connections even though your code say it should.

      Write a Reply...