Re: Freeing Memory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>
> How does that work considering that mysql_query() only
> returns true or false on INSERT? I'd expect the script
> to fail on $result not being a valid resource.
>

I don't know about mysql as I work with MSSQL Server and Informix, but for
me it works like this:

   $insert = ifx_prepare("INSERT INTO my_table
          VALUES ('0')", $connect_id);
   ifx_do($insert) or die ("Query failed");
   ifx_free_result($insert);

By using PREPARE and DO to execute the queries it allows ifx_free_result to
release those resources.

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux