Skip to Content.
Sympa Menu

freetds - Re: [freetds] MS SQL stored proceedure OUTPUT bindings and return codes?

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Martin Bonner" <martin.bonner AT argentas.co.uk>
  • To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] MS SQL stored proceedure OUTPUT bindings and return codes?
  • Date: Fri, 17 Oct 2003 23:54:45 +0100

> From: "Martin Bonner" <martin.bonner AT argentas.co.uk>
> Sent: Friday, October 17, 2003 10:09 PM
>
> I'm trying to gain access to both the return value of a stored proceedure
> and bind to its OUTPUT variables without much success.
>
> I don't appear to get a results set for the OUTPUT variables and the
results
> set of type 4043 (CS_STATUS_RESULTS) always contains a value of '0'
> regardless of the value returned by the stored proceedure.

Right, I've mananged to find some references in the archives to the changes
made in MS SQL 7.0 SP3 which change the way that the server responds when
using TDS 7.0, and sure enough, using TDS 4.2 results in the output bindings
working as I was expecting originally:-

resulttype: 4043 (CS_STATUS_RESULT)
$VAR1 = {
'COL(1)' => 0
};
resulttype: 4042 (CS_PARAM_RESULT)
$VAR1 = {
'@outvar' => 6
};

What i'm still not clear on though, is:
a) why the return value always comes back as 0 regardless of the value
returned by my stored procedure..
b) whether it is possible to retrieve the above OUTPUT bindings in some
other way when using TDS 7.0 with DBD::Sybase or whether this is still work
in progress..

Thanks in advance for any info....

Regards,
Martin





Archive powered by MHonArc 2.6.24.

Top of Page