Re: Display Result in PHP after select statement

From: Date: Tue, 29 Aug 2000 01:00:43 +0000
Subject: Re: Display Result in PHP after select statement
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-14034@lists.php.net to get a copy of this message
If you are talking about MySQL, then you should read through the "MySQL Functions" section of the PHP manual. You can use mysql_num_fields() to find how many fields (columns) are in the results of the select, and use a loop with mysql_field_name() to print out the names of all the fields. You can use mysql_num_rows() to know how many rows got returned by the select. Wee Chua wrote: > > Hi everyone, > Good Morning! I need a help on displaying data on the screen after the > select statement. However, I would to make the php codes independent and > flexible, it could display the fields and rows as many as user request. > Different tables have different amount of columns to display after the > select statement. Could anyone tell me the simple codes I should write in > php, please? > > Calvin > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net -- -------------------- To send e-mail to me replace the domain name with djdesign.com The phony "anti.spam" domain is used to fool newsgroup e-mail address harvestor 'bots. ----------------------

« previous php.general (#14034) next »