in reply to DBD::Sybase stored procedure question
The following works:
Michael#!/usr/bin/perl -w + use strict; use DBI qw(:sql_types); + my $dbh = DBI->connect('dbi:Sybase:server=SYBASE;database=testdb', 'sa +', 'some password'); + my $sth = $dbh->prepare("exec spSubComponentAdd \@subComponentName = ? +, \@subComponentDescription = ?, \@subComponentId = ? output"); $sth->bind_param(1, "one"); # bind_param() defaults to SQL_CHAR. $sth->bind_param(2, "two"); $sth->bind_param(3, undef, SQL_INTEGER); $sth->execute; + my (@data) = $sth->func('syb_output_params'); print "Got @data\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: DBD::Sybase stored procedure question
by martymart (Deacon) on Sep 10, 2004 at 15:00 UTC | |
by mpeppler (Vicar) on Sep 10, 2004 at 15:08 UTC |