Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Re: two connections to the same database with DBD::Sybase

by mpeppler (Vicar)
on Dec 10, 2002 at 16:42 UTC ( [id://218824]=note: print w/replies, xml ) Need Help??


in reply to Re: two connections to the same database with DBD::Sybase
in thread two connections to the same database with DBD::Sybase

I see you found it... I know that the DBI docs specify that $sth->finish is in general not needed, but in the type of code that you used there is no way for DBD::Sybase to realize that there are no results after the single row fetched through the $sth2 handle (well, it could do a look-ahead fetch, but then it would have to store the fetched row somewhere until the script calls fetch() again. Feasible, but messy).

I should probably improve the documentation a bit to be more explicit about the need to finish executions properly, either by fetching until no more rows are found, or by using finish().

Michael

Replies are listed 'Best First'.
Re: Re: Re: two connections to the same database with DBD::Sybase
by busunsl (Vicar) on Dec 11, 2002 at 09:11 UTC
    I should probably improve the documentation a bit to be more explicit about the need to finish executions properly, either by fetching until no more rows are found, or by using finish().

    This might help, but not me ;-(

    One thing I always pray when talking about DBI is: Always finish your statements!

    And then I didn't do it myself :-(

    Perhaps there is room for enhancement somewhere else.
    If there had been the connection parameters (server, database) somewhere in the error messages, I would have found the error earlier.

    Michael, this is a feature request ;-)

      I know it's been almost a year, but DBD::Sybase 1.01 (to be released RSN) won't require the finish request in this situation any more.

      Michael

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://218824]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (3)
As of 2024-04-26 02:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found