Re: Only one value.
| From: | Michael Kimsal | Date: | Sun, 27 Jan 2002 20:50:42 +0000 |
| Subject: | Re: Only one value. | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-82318@lists.php.net to get a copy of this message | ||
Philip J. Newman wrote:
Don't know is this is a Mysql problem or PHP, but I have a table with 100 records in it. One of the field names is $iName. When listing all the records I want only the 1st Uneak value to be displayed. For excample if values where, Bob, Jan, Mike, James, Bob, James, James, Mike ... I would like to call: Bob, Jan, Mike, James ... Any IdenasI suspect you mean the mysql field name is 'iName', not '$iname' ($iName being the PHP variable name). try select distinct(iName) from tablename and loop through those result sets. Michael Kimsal http://www.tapinternet.com/php/ PHP Training Courses 734-480-9961