PEPPLER.ORG
Michael Peppler
Sybase Consulting
Menu
Home
Sybase on Linux
Install Guide for Sybase on Linux
General Sybase Resources
General Perl Resources
Freeware
Sybperl
Sybase::Simple
DBD::Sybase
BCP Tool
Bug Tracker
Mailing List Archive
Downloads Directory
FAQs
Sybase on Linux FAQ
Sybperl FAQ
Personal
Michael Peppler's resume

sybperl-l Archive

Up    Prev    Next    

From: Michael Peppler <mpeppler at peppler dot org>
Subject: Re: Sybase::Simple not getting stored proc return status
Date: Apr 30 2004 4:04PM

On Fri, 2004-04-30 at 17:54, Graham Hick wrote:

> 
> This is a change in behaviour compared to earlier versions (0.51 in
> particular).  In 0.51, Scalar will return the stored proc return status,
> unless the proc creates any result sets of its own.  In 0.56, Scalar
> returns undef unless the proc creates its own result set.

Sorry about that.

I *think* that if you change the last line of the Scalar() subroutine
from 
	$data[0];
to
	$data[0] || $status;

you should get the desired behavior.

The return status is also available in $dbh->{SIMPLE}->{STATUS} after
Scalar() returns.

Michael
-- 
Michael Peppler                              Data Migrations, Inc.
mpeppler@peppler.org                       http://www.peppler.org/
Sybase T-SQL/OpenClient/OpenServer/C/Perl developer available for short
or long term contract positions - http://www.peppler.org/resume.html