DBD::ODBC::st execute failed: [Microsoft][ODBC SQL Server Driver]Invalid cursor state (SQL-24000)(DB D: dbd_describe/SQLNumResultCols err=-1) at H:\progs\dbi_test.pl line 10. #### #c:/perl/bin/perl use DBI; my $dbh = DBI->connect( 'dbi:ODBC:TEST_DSN', '','', {RaiseError=> 1} ); my $sth = $dbh->prepare( "PRINT '...begin' select name = 'test' " ); my $rv = $sth->execute(); print "rv: $rv \n"; while ( my $hr = $sth->fetchrow_hashref ){ print $$hr{$_}, "\n" for ( keys %$hr ); print "Err: ", $dbh->errstr, "\n" if $dbh->errstr; }