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: How to the no of rows
Date: May 1 2000 2:10PM

venkat Reddy writes:
 >   hi,
 > 
 >  How do I know the number of rows in any table? After the select query executed.How can I find out the query returned 0 rows or x rows?
 > 

*After* you have retrieved all the rows of a SELECT query you can use
DBCOUNT() (using DBlib) or ct_res_info(CS_ROW_COUNT).

There is NO way of knowing the EXACT number of rows that will be
returned by a query *before* having retrieved all the rows.

Michael
-- 
Michael Peppler         -||-  Data Migrations Inc.
mpeppler@peppler.org    -||-  http://www.mbay.net/~mpeppler
Int. Sybase User Group  -||-  http://www.isug.com
Sybase on Linux mailing list: ase-linux-list@isug.com