Miguel, What you want is mysql_num_rows() after a SELECT call.
John >Hello, I work PHP environment. I use to call Mysql_Affected_Rows to get >number of records retrieved by SELECT commands. >This works fine for some scripts, but now I got a script which returns >qtty records = -1, even I know these records exists. >I review Mysql manual and notice this function just returns qty records >for UPDATE, INSERT or DELETE commands, but not for SELECT commands. >Am I making wrong?, is there some function just to retrieve qty records >selected in a query? > >Thanks in advance > >Miguel -- /* SteeleSoft Consulting John Steele - Systems Analyst/Programmer * We also walk dogs... Dynamic Web Design PHP/MySQL/Linux/Hosting * www.steelesoftconsulting.com [EMAIL PROTECTED] */ --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php