Gurus,
Is there anybody out there that can give an example of calling a stored proc from
within perl and then fetch the result set returned by the proc?
I have always run into trouble when I have tried doing this from ActiveState to call
procs in ms sql server. I find it easier to call procs that does inserts , deletes
etc. however can not deal with the ones that returns result sets back to the program
with select statements. Is this a cursor issue in perl??
A template to general syntax is like:
$query = qq( {call proc_Number_Rule_Validate(?)} );
$sth = $db->prepare($query);
$sth->bind_param(1, $arg);
$sth->execute or croak "Error executing the statement: $DBI::errstr";
#proc_Number_Rule_Validate() returns a resultset.
# do fetching here...
An answer is much appreciated.
Cheers,
Ozgur