http://qs321.pair.com?node_id=504006


in reply to Re^2: Getting MSSQL message return on DBI
in thread Getting MSSQL message return on DBI

I am not sure I understand your question. But if you are wondering how to get the results of a statement handle with multiple result sets you should have code like:
my @rs; #result set do { while( my $hr = $sth->fetchrow_hashref ){ push @rs, $hr; } #process @rs (array of hashrefs in order the server returned them ) } while ( $sth->{odbc_more_results} );
If your question is about the error still, then you need to read perldoc DBI and DBD::ODBC for more specifics on how errors are handled an some suggestions on methods to do that. There are some additional flags you can set in both the db handle such as { RaiseError=> 1 } and in the statement handle. In general a common error handle method is to wrap your calls in eval {}; and check $@.