Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: error trapping problem

by mpeppler (Vicar)
on Feb 22, 2006 at 19:12 UTC ( [id://532064]=note: print w/replies, xml ) Need Help??


in reply to error trapping problem

Executing that script via DBD::Sybase would be a lot easier to trap the errors.

That's pretty straightforward - you just need to read in the file and split it on the \ngo\n. Then submit each SQL block with a loop:

$sth = $dbh->prepare($sql); do { while(my $row = $sth->fetch) { print "@$r\n"; } } while($sth->{syb_more_results});
Michael

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (2)
As of 2024-04-20 11:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found