Skip to content

PHP : ingres-1.4.1 released

Yesterday I released version 1.4.1 of the PECL Ingres extension. Mainly a bug fix release fixing some interesting SEGV/GPFs with different web servers.

  • Added environment check during initialization
  • Fixed SEGV when closing a statement
  • Fixed spurious E_WARNING with empty LOB dataset
  • Fixed SEGV when ingres_close() is not called
  • Fixed auto commit cannot be enabled on shutdown
  • Fixed Array index start for php_ii_field_name
  • Fixed constant typo

Now that is out of the way I will be looking at the next “major” release of the extension. In particular a change to support multiple result sets. Unfortunately this will require a breakage in backwards compatibility with the way things work at present. For example to run a query now the function ingres_query() is called as followed:
$rc = ingres_query ($sql, $link)or
$rc = ingres_query ($sql)

As you can tell the $link parameter is optional. This will no longer be the case. Also instead the function will not give a return code rather a result resource for ingres_fetch_*. So a simple (no error checking) connect, query, fetch, disconnect will go as follows:

$link = ingres_connect($dbname, $user, $password, $options);
$sql = "select * from iirelation";
$result = ingres_query($link, $sql);
while ( $iirelation = ingres_fetch_object($result) )
{
echo $iirelation->relid . "<br/>\n";
.
.
}
/* release the result set */
ingres_free ($result)
ingres_close ($link)

As you can see it is a bit different and is most likely to cause breakage in any PHP application that makes use of Ingres but it is a necessary change. If you have any comments or suggestions you can email via grantc@php.net

Some random posts

blog comments powered by Disqus