[DB-SIG] mxODBC: Function sequence error

Hornberger, Chris Chris.Hornberger at blackrock.com
Mon May 24 09:18:00 EDT 2004


What about, rather than handing out cursors to threads, you stacked/queued your requests, and have a centralized db manager? That way you only have to lock the queue object during pop/push actions, and part of the "job" object you stack up can have a call back thru' which you return the results.

--------------------------
Chris Hornberger
Blackrock - 302.797.2318
chris.hornberger at blackrock.com

Card carrying MSDN member since 2004.
No, really. I've got the card to prove it.


-----Original Message-----
From: db-sig-bounces at python.org [mailto:db-sig-bounces at python.org]On
Behalf Of Thomas Waechter
Sent: Monday, May 24, 2004 9:12 AM
To: db-sig at python.org
Cc: mal at egenix.com
Subject: Re: [DB-SIG] mxODBC: Function sequence error


M.-A. Lemburg wrote:
 > Are you using one connection per thread ?
In our framework, on each connection operate several cursors normally 
having their own thread. So each thread only workes on one connection 
but there can be more threads per connection.

 > Please also make sure that you're using the latest available
 > ODBC drivers for MS Access, since earlier versions are not
 > thread safe.
think so. I am using Microsoft Access Driver 4.00.6019.00. I installed 
MDAC 2.8 and Jet 4.0 Service Pack 8 (SP8).  These should be the newest 
available versions.

But still the same problem occurs. I mutually excluded all my calls to 
mxODBC to literally serialize them. I expected it to run slow, but the 
threads shouldn't be able to interfere anymore. But still it crashes 
with the same "function sequence error" and works if I only allow one 
thread to be used.


 > No need to recompile: direct is set to 1 if you execute
 > an SQL statement without parameters or you switch to
 > .executedirect().
At the moment, I haven't got a clue how to work out where the problem 
might be located. Though I encapsulated all calls to mxODBC with 
exclusive locks, I cannot understand how this error can occur.

Which additional information will the debug option of mxODBC provide? Is 
it worth to try it to find out more about the "function sequence error"?

Thanks Thomas

-- 
Thomas Waechter
Software Developer
Cenix BioScience
BioInnovations Zentrum
Tatzberg 46
D-01307
Dresden
Germany

Tel : +49 (0)351 4173 0155
e-mail : waechter at cenix-bioscience.com
Cenix Website : http://www.cenix-bioscience.com


_______________________________________________
DB-SIG maillist  -  DB-SIG at python.org
http://mail.python.org/mailman/listinfo/db-sig



More information about the DB-SIG mailing list