Re: Mysql join and aliasing with mysql_fetch_object()
| From: | Richard Lynch | Date: | Fri, 03 Aug 2001 02:52:52 +0000 |
| Subject: | Re: Mysql join and aliasing with mysql_fetch_object() | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-61063@lists.php.net to get a copy of this message | ||
> select tableA.*, tableB.* from tableA,
> left join tableB ON tableA.keyfield = tableB.keyfield
>
> When I then try to access the column "keyfield", after using
select tableA.keyfield as mykeyfield, tableA.*, tableB.* ...
Unless you actually need *EVERY* field, do *NOT* use tableA.*, tableB.*
Every piece of data you ask for takes time and resources in MySQL and PHP.
--
WARNING richard@zend.com address is an endangered species -- Use
ceo@l-i-e.com
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm