2 columns same name cuz of a join
| From: | Jason Jacobs | Date: | Mon, 26 Feb 2001 19:49:07 +0000 |
| Subject: | 2 columns same name cuz of a join | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-41729@lists.php.net to get a copy of this message | ||
Hi again. :) Does anyone know how to reference a value in an array or
object if the returned table has 2 fields of the same name. IE, I am
querying 2 tables and returning an id value from each. On both tables, the
id fieldname is "id". I know I can access the vals like $array[0] and
$array[1], but is there a way I can fetch_object do do that? Can I
reference them like $object->table1.id and $object->table2.id? I would
assume not since it just makes a new table when it returns the data. Thanks
for the help, and I hope my question is clear. :)
Jason