You should call mysql_free_result($Query) !!

It all becomes a little clearer if you change the names of the variables as
such:

$result = mysql_query("select ...");
$row = mysql_fetch_assoc($result);

That is, mysql_query() returns a "result", and mysql_fetch_*() returns a
"row" from such a result. Using mysql_free_result on a row is not advisable.

Also, in my terminology, the "query" would be the string passed to
mysql_query(), so you could do like this:

$query = "select ...";
$result = mysql_query($query);
$row = ...

Regards,
Jakob Kruse

"Chris Cameron" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I'm a bit unclear as to which result it is I use this function on.
> So lets say I;
> $Query = mysql_query("SELECT something FROM here");
> $Result = mysql_fetch_assoc($Query);
>
> Do I mysql_free_result the $Query or the $Result? If it's $Result, would
> this be the same as just going unset($Result)?
>
> Thanks,
> Chris
>
> --
> "If you don't find it in the index, look very carefully through the entire
catalogue."
> - Sears, Roebuck, and Co., Consumer's Guide, 1897




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to