A
Anonymous
Guest
I couldn't find the PostgreSQL channel. So I choose the nearest one, mySQL. I'm sorry if my post is OOT. Don't focus at the dirty codes, but I need to know the answer in database perspective.
if I have a script like this :
$db = pg_connect("host=localhost dbname=temp user=user")
$result = pg_query($db,"SELECT * from MyTable");
list($a, $b, $c) = pg_fetch_row($result);
pg_free_result($result);
pg_close($db);
// end of code
My question is, does the free result function need to be called after using?
MySQL has this kind of function, hasn't it?
Actually I've done so many database script without calling the free result function, and nothing matters. I'm just curious what is the effect of this function.
Thanks.
Jenny.
if I have a script like this :
$db = pg_connect("host=localhost dbname=temp user=user")
$result = pg_query($db,"SELECT * from MyTable");
list($a, $b, $c) = pg_fetch_row($result);
pg_free_result($result);
pg_close($db);
// end of code
My question is, does the free result function need to be called after using?
MySQL has this kind of function, hasn't it?
Actually I've done so many database script without calling the free result function, and nothing matters. I'm just curious what is the effect of this function.
Thanks.
Jenny.