php-doc-en/reference/ingres-ii/reference.xml
Hannes Magnusson c030e2adf7 Upgrade to DocBook5:
- All id attributes are now xml:id
 - Add docbook namespace to all root elements
 - Replace <ulink /> with <link xlink:href />
 - Minor markup fixes here and there


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@238160 c90b9560-bf6c-de11-be94-00142212c4b1
2007-06-20 22:25:43 +00:00

119 lines
3.2 KiB
XML

<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.13 $ -->
<!-- Purpose: database.vendors -->
<!-- Membership: pecl, external -->
<reference xml:id="ref.ingres" xmlns="http://docbook.org/ns/docbook">
<title>Ingres II Functions</title>
<titleabbrev>Ingres II</titleabbrev>
<partintro>
<section xml:id="ingres.intro">
&reftitle.intro;
<para>
These functions allow you to access Ingres II database servers.
</para>
<note>
<para>
If you already used PHP extensions to access other database
servers, note that Ingres doesn't allow concurrent queries and/or
transaction over one connection, thus you won't find any result
or transaction handle in this extension. The result of a query
must be treated before sending another query, and a transaction
must be committed or rolled back before opening another
transaction (which is automatically done when sending the first
query).
</para>
</note>
</section>
<section xml:id="ingres.requirements">
&reftitle.required;
<para>
To compile PHP with Ingres support, you need the Ingres OpenAPI library
and header files.
</para>
</section>
&reference.ingres-ii.configure;
&reference.ingres-ii.ini;
<section xml:id="ingres.resources">
&reftitle.resources;
<para>
<function>ingres_connect</function> and
<function>ingres_pconnect</function> return an Ingres II link identifier.
</para>
</section>
&reference.ingres-ii.constants;
<section xml:id="ingres.examples">
&reftitle.examples;
<para>
This simple example shows how to connect, execute a query, print
resulting rows and disconnect from an Ingres database.
<example>
<title>Simple Ingres Example</title>
<programlisting role="php">
<![CDATA[
<?php
// Connecting, selecting database
$link = ingres_connect('database', 'user', 'password')
or die('Could not connect: ' . ingres_error($link));
echo 'Connected successfully';
// Select from a table that exists in all Ingres databases
$query = 'SELECT * FROM iirelation';
$returncode = ingres_query($query,$link) or die('Query failed: ' .
ingres_error($link));
// Print results in HTML
// relid - table name
// relowner - table owner
echo "<table>\n";
while ($iirelation = ingres_fetch_object(INGRES_BOTH, $link)) {
echo "\t<tr>\n";
echo "\t\t<td>" . $iirelation->relid . "</td>\n";
echo "\t\t<td>" . $iirelation->relowner . "</td>\n";
echo "\t</tr>\n";
}
echo "</table>\n";
// Commit transaction
ingres_commit($link);
// Closing connection
ingres_close($link);
?>
]]>
</programlisting>
</example>
</para>
</section>
</partintro>
&reference.ingres-ii.functions;
</reference>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->