in reply to Re: SQL Stored Procedure return value
in thread SQL Stored Procedure return value

I'm uncertain how FreeTDS handles this, but the following should work:
$sth = $dbh->prepare(" declare \@ret numeric exec TEST \@results=@ret select @ret "); $sth->execute; do { while($d = $sth->fetch) { print "@$d\n"; } } while($sth->{syb_more_results});
(with appropriate error handling, of course).

Michael

Replies are listed 'Best First'.
Re: Re: Re: SQL Stored Procedure return value
by gnangia (Scribe) on Jul 18, 2003 at 03:41 UTC
    Michael, Which Sybase libraries/drivers do I need to download to get DBD::Sybase to work with?
    Thank-you
      Hmmm - that should be valid SQL syntax. I don't have FreeTDS or MS-SQL, but I just tried this with Sybase and it works correctly.

      Maybe you need to ask on the FreeTDS mailing list?

      Michael

        Michael, Which Sybase libraries/drivers do I need to download to get DBD::Sybase to work with?
        Thank-you