Re: Only 1 Query Result...help.

From: Date: Tue, 16 Oct 2001 11:05:19 +0000
Subject: Re: Only 1 Query Result...help.
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-71196@lists.php.net to get a copy of this message
Guys, While you are in a debating mood: Why is there such similarity and overlap between mysql_fetch_array(resource result, MYSQL_ASSOC) [PHP 4 >= 4.0.0] and mysql_fetch_assoc() [PHP 4 >= 4.0.3] ? I appreciate that both are considered (slightly) less efficient than 'fetch_row', and there is another comment (null values) in the annotated manual. However both are fairly recent additions, and one apparently grew out of the other; but is there an efficiency issue or thoughts of future deprecation to lead us to prefer one over the other? Please advise, =dn > > conclusion: fetch_row is more efficient, but does it really make that much > > difference? > > No. From the manual : > > An important thing to note is that using mysql_fetch_array() > is NOT significantly slower than using mysql_fetch_row(), > while it provides a significant added value. > > Also, fetch_array has optional second arguments to consider. At any rate, > let's conclude that it's personal preference :)

« previous php.general (#71196) next »