Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?

Re^4: Perl DBI connect cached still active

by derby (Abbot)
on Oct 30, 2020 at 10:43 UTC ( #11123305=note: print w/replies, xml ) Need Help??

in reply to Re^3: Perl DBI connect cached still active
in thread Perl DBI connect cached still active

Corion++ Sybase will fail if you finish an sth when there are unread results. You can override that by setting the syb_flush_finish attribute

my $prod_dbh = DBI->connect_cached('DBI:Sybase:database','web_','web +' {syb_flush_finish => 1})
but that wouldn't be my recommendation. I find most cases of extracting data are better suited by using selectall_arrayref. Sure you lose the re-usability of prepared statements (I only used those if I'm in a loop) and you may have memory issues if the data being returned is huge but I find the vast majority of my use cases are better served by the simplicity of selectall_arrayref:
my $parent_data = $prod_dbh->selectall_arrayref('select * from table + where id = ?', {Slice => {}}, $id );

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (4)
As of 2022-01-23 10:26 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (63 votes). Check out past polls.