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: "Kiriakos Georgiou" <kirig at library dot nrl dot navy dot mil>
Subject: RE: NUMBER of affected rows
Date: May 10 2001 12:38PM

I have had similar experiences using DBI's $sth->rows - it's usually
not available.

-K

-----Original Message-----
From: owner-SYBPERL-L@list.cren.net
[mailto:owner-SYBPERL-L@list.cren.net]On Behalf Of Karsten Spakowski
Sent: Thursday, May 10, 2001 7:26 AM
To: SybPerl Discussion List
Subject: NUMBER of affected rows


Hi folks,

I work with the DBI and DBD Module on a Sybase Server 11.9.

After the execution of an select statement,  I will check the number
of
affected row,
but I get always the -1.

my $sth = $dbh->prepare("Select name from patient
                                            where name =
\"Anybody\"");
my $rc = $sth->execute();
print "$rc affected rows \n";

while (my @row = $sth->fetchrow_array()) {
    print "Row: @row \n";
}

Even if I have some affected data,
the variable $rc told me always the number of affected rows are
unknown.

Does anybody  know what could be causing this problem?

Thanks in advance.
Karsten Spakowski