[Zope-DB] DCOracle2 OracleDate and parameter sequence problem

Matthew T. Kromer matt@zope.com
Mon, 15 Oct 2001 11:15:58 -0400


Christopher Jenkins wrote:

>"Matthew T. Kromer" wrote:
>
>>OK, for what its worth, I downloaded Oracle 9i over (I think my first DL
>>was bad) burned it, took it home, and tried to install it last night.
>> After twiddling with gencliensh to build libclientsh.so (of which I am
>>not sure what I did was CORRECT) I finally got a 9i database up on
>>RedHat 7.1.
>>
>>I was able to reproduce your problem, mostly.   What I found was that
>>any array based executemany() was failing one way, and the dynamic fetch
>>mode was failing with the error "arrays can only be bound to PL/SQL
>>statments" which is a sort of "aha!" because it generally implies the
>>binding arguments are being interpreted differently.
>>
>>Sadly, it took so long to do most of the above I didnt have much time
>>left to do much analysis.
>>
>
>Thanks for going to this trouble.  I only hope that after
>this amount of effort you will be able to resolve the problems.
>
>I should also apologise for posting tracedumps to the mailing
>list - I will be more careful in future.
>
>Chris
>

OK Chris, in the stuff that I checked in this morning, I made it so that 
if you comment out the setStatic() line in DCOracle2.py, the stest.py 
test script passes under Oracle 9i.  I still don't know why the static 
bind is failing, but the dynamic bind was failing because it was being 
set up as a PL/SQL array bind.  

Caveat:  I havent thrown a tougher insert test at this yet; the whole 
reason static binds are the default is to prevent the case when oracle 
occasionally forgets to call back the callback function for dynamic 
binds.  Testing large inserts that do not allow NULL columns used to 
fail on Linux when the OCI callback didnt trigger (on an apparently 
random basis).