[unixODBC-support] failure on disconnect with immediate re-connect

Bob Marcum bmarcum at houston.rr.com
Mon Jan 1 02:29:24 GMT 2007



>>
>> Can you tell what I may be doing wrong?
>>
>> Thanks so much!
>>

> Hmm, that looks fine, its just calling SQLDriverConnect on the handle 
> that its just called SQLDisconnect on.
> 
> What unixODBC version are you using?

unixODBC-2.2.12

> 
> If you run in single user mode under a debugger, does it give ny clues
> 
> gdb httpd
> r -X
> 
> Then when it crashes
> 
> bt
> 
> to show where it failed.
> 

Well ... I have been chasing this for about two weeks now.  I think I am going to wire around whatever the problem is by architecting around the problem.  I have changed the approach from getting a new connect upon entering each routine which does a select, create, update, or delete then doing a disconnect at the end of the routine ... to ... getting a single connect upon initialization and using that connect for whatever I do with the database.  Since this is a web-based program it executes once for each request for service and each request does only one thing with the database, some of which "one thing" may make multiple statements, each executing to preform the service.  But now having re-architected (took about 30 minutes) I no longer have any database access problems.

Thanks for taking a lok at this.




More information about the unixODBC-support mailing list