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: ct_sql and return code
Date: Nov 8 2001 7:53PM

Wohlgemuth, Michael J. writes:
 > I've got a question about ct_sql and return codes.  I'm running SybPerl 2.13
 > with Perl 5.005_02 under Solaris 2.7.  I've got the following snippet of
 > code:
 > 
 > $sql = new Sybase::CTlib $username, $password, $host;
 > $ref = $sql->ct_sql ("use $DB");
 > $ref = $sql->ct_sql ($query);
 > $rc = $sql->{RC};
 > 
 > The query executes properly, and I get the results I expect, but $rc gets
 > set to -205.  The docs imply that it should only be one of CS_SUCCESS,
 > CS_FAIL, or CS_CANCELED (and CS_CANCELED really shouldn't apply in this
 > case, if I understand correctly).  Anyway -205 is not any of these.  Is
 > there a comprehensive list of possible values of RC somewhere?

-205 is CS_END_RESULTS.

The RC attribute is the last value returned by ct_results(), or
CS_FAIL if ct_results() returned a CS_CMD_FAIL for the restype value
at any point in the sequence.

Michael
-- 
Michael Peppler - Data Migrations Inc. - http://www.mbay.net/~mpeppler
mpeppler@peppler.org - mpeppler@mbay.net
International Sybase User Group - http://www.isug.com