mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
Update for new functionality
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@222371 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
553bc8304a
commit
bece7e0272
4 changed files with 308 additions and 9 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.8 $ -->
|
||||
<!-- $Revision: 1.9 $ -->
|
||||
<section id="ingres.constants">
|
||||
&reftitle.constants;
|
||||
&extension.constants;
|
||||
|
@ -204,6 +204,102 @@
|
|||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>
|
||||
<constant>INGRES_STRUCTURE_BTREE</constant>
|
||||
(<type>integer</type>)
|
||||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Specifies the default table or index structure to BTREE when used in combination with the
|
||||
table_structure or index_structure option when connecting. Available since version 1.4.0 of the PECL extension.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>
|
||||
<constant>INGRES_STRUCTURE_CBTREE</constant>
|
||||
(<type>integer</type>)
|
||||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Specifies the default table or index structure to COMPRESSED BTREE when used in combination with the
|
||||
table_structure or index_structure option when connecting. Available since version 1.4.0 of the PECL extension.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>
|
||||
<constant>INGRES_STRUCTURE_HASH</constant>
|
||||
(<type>integer</type>)
|
||||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Specifies the default table or index structure to HASH when used in combination with the
|
||||
table_structure or index_structure option when connecting. Available since version 1.4.0 of the PECL extension.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>
|
||||
<constant>INGRES_STRUCTURE_CHASH</constant>
|
||||
(<type>integer</type>)
|
||||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Specifies the default table or index structure to COMPRESSED BTREE when used in combination with the
|
||||
table_structure or index_structure option when connecting. Available since version 1.4.0 of the PECL extension.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>
|
||||
<constant>INGRES_STRUCTURE_HEAP</constant>
|
||||
(<type>integer</type>)
|
||||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Specifies the default table structure to HEAP when used in combination with the
|
||||
table_structure option when connecting. Available since version 1.4.0 of the PECL extension.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>
|
||||
<constant>INGRES_STRUCTURE_CHEAP</constant>
|
||||
(<type>integer</type>)
|
||||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Specifies the default table structure to COMPRESSED HEAP when used in combination with the
|
||||
table_structure option when connecting. Available since version 1.4.0 of the PECL extension.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>
|
||||
<constant>INGRES_STRUCTURE_ISAM</constant>
|
||||
(<type>integer</type>)
|
||||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Specifies the default table or index structure to ISAM when used in combination with the
|
||||
table_structure or index_structure option when connecting. Available since version 1.4.0 of the PECL extension.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term>
|
||||
<constant>INGRES_STRUCTURE_CISAM</constant>
|
||||
(<type>integer</type>)
|
||||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Specifies the default table or index structure to COMPRESSED ISAM when used in combination with the
|
||||
table_structure or index_structure option when connecting. Available since version 1.4.0 of the PECL extension.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
</section>
|
||||
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.5 $ -->
|
||||
<!-- $Revision: 1.6 $ -->
|
||||
<!-- splitted from ./en/functions/ingres_ii.xml, last change in rev 1.1 -->
|
||||
<refentry id="function.ingres-connect">
|
||||
<refnamediv>
|
||||
<refname>ingres_connect</refname>
|
||||
<refpurpose>
|
||||
Open a connection to an Ingres II database
|
||||
Open a connection to an Ingres database
|
||||
</refpurpose>
|
||||
</refnamediv>
|
||||
<refsect1>
|
||||
|
@ -15,9 +15,10 @@
|
|||
<methodparam choice="opt"><type>string</type><parameter>database</parameter></methodparam>
|
||||
<methodparam choice="opt"><type>string</type><parameter>username</parameter></methodparam>
|
||||
<methodparam choice="opt"><type>string</type><parameter>password</parameter></methodparam>
|
||||
<methodparam choice="opt"><type>array</type><parameter>options</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
Returns a Ingres II link resource on success, or &false; on
|
||||
Returns a Ingres link resource on success, or &false; on
|
||||
failure.
|
||||
</para>
|
||||
<para>
|
||||
|
@ -30,7 +31,7 @@
|
|||
If some parameters are missing, <function>ingres_connect</function>
|
||||
uses the values in &php.ini; for
|
||||
<parameter>ingres.default_database</parameter>,
|
||||
<parameter>ingres.default_user</parameter>, and
|
||||
<parameter>ingres.default_user</parameter> and
|
||||
<parameter>ingres.default_password</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
|
@ -42,6 +43,148 @@
|
|||
default, so you need to store the returned value only if you use
|
||||
more than one link at a time.
|
||||
</para>
|
||||
<para>
|
||||
<function>ingres_connect</function> options
|
||||
<informaltable>
|
||||
<tgroup cols='2'>
|
||||
<thead>
|
||||
<row>
|
||||
<entry>Option name</entry>
|
||||
<entry>Description</entry>
|
||||
</row>
|
||||
</thead>
|
||||
<tbody>
|
||||
<row>
|
||||
<entry>date_century_boundary</entry>
|
||||
<entry>The threshold by which a 2 digit year is determined to be in
|
||||
the current century or in the next century. Equivalent to II_DATE_CENTURY_BOUNDARY. </entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>group</entry>
|
||||
<entry>Speficfies the group ID of the user, equivalent to the '-G'
|
||||
flag</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>role</entry>
|
||||
<entry>The role ID of the application. If a role password is
|
||||
required, the parameter value should be specified as "role/password"</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>effective_user</entry>
|
||||
<entry>The ingres user account being impersonated, equivalent to the '-u' flag</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>dbms_password</entry>
|
||||
<entry>The internal database password for the user connecting to Ingres</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>table_structure</entry>
|
||||
<entry>The default structure for new tables. Valid values for
|
||||
table_structure are:
|
||||
<itemizedlist>
|
||||
<listitem><simpara>INGRES_STRUCTURE_BTREE</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_HASH</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_HEAP</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_ISAM</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_CBTREE</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_CISAM</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_CHASH</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_CHEAP</simpara></listitem>
|
||||
</itemizedlist>
|
||||
</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>index_structure</entry>
|
||||
<entry>The default structure for new secondary indexes. Valid values
|
||||
for index_structure are:
|
||||
<itemizedlist>
|
||||
<listitem><simpara>INGRES_STRUCTURE_CBTREE</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_CISAM</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_CHASH</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_BTREE</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_HASH</simpara></listitem>
|
||||
<listitem><simpara>INGRES_STRUCTURE_ISAM</simpara></listitem>
|
||||
</itemizedlist>
|
||||
</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>login_local</entry>
|
||||
<entry>Determines how the connection user ID and password are
|
||||
used when a VNODE is included in the target database string.
|
||||
If set to TRUE, the user ID and password are used to locally access
|
||||
the VNODE and the VNODE login information is used to establish the DBMS
|
||||
connection. If set to FALSE, the process user ID is used to access
|
||||
the VNODE and the connection user ID and password are used in place
|
||||
of the VNODE login information to establish the DBMS connection.
|
||||
This parameter is ignored if no VNODE is included in the target
|
||||
database string. The default is FALSE.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>timezone</entry>
|
||||
<entry>Controls the timezone of the session. If not set it will
|
||||
default the the value defined by II_TIMEZONE_NAME. If
|
||||
II_TIMEZONE_NAME is not defined the NA-PACIFIC (GMT-8 with Daylight
|
||||
Savings) is used.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>date_format</entry>
|
||||
<entry>Sets the allowable input and output format for Ingres dates.
|
||||
Defaults to the value defined by II_DATE_FORMAT. If II_DATE_FORMAT is
|
||||
not set the default date format is US, e.g. mm/dd/yy. Valid values
|
||||
for date_format are:
|
||||
<itemizedlist>
|
||||
<listitem><simpara>INGRES_DATE_DMY</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_FINISH</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_GERMAN</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_ISO</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_ISO4</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_MDY</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_MULTINATIONAL</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_MULTINATIONAL4</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_YMD</simpara></listitem>
|
||||
<listitem><simpara>INGRES_DATE_US</simpara></listitem>
|
||||
</itemizedlist>
|
||||
</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>decimal_separator</entry>
|
||||
<entry>The character identifier for decimal data</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>money_lort</entry>
|
||||
<entry>Leading or trailing currency sign. Valid values for money_lort
|
||||
are:
|
||||
<itemizedlist>
|
||||
<listitem><simpara>INGRES_MONEY_LEADING</simpara></listitem>
|
||||
<listitem><simpara>INGRES_MONEY_TRAILING</simpara></listitem>
|
||||
</itemizedlist>
|
||||
</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>money_sign</entry>
|
||||
<entry>The currency symbol to be used with the MONEY datatype</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>money_precision</entry>
|
||||
<entry>The precision of the MONEY datatype</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>float4_precision</entry>
|
||||
<entry>Precision of the FLOAT4 datatype</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>float8_precision</entry>
|
||||
<entry>Precision of the FLOAT8 data</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>blob_segment_length</entry>
|
||||
<entry>The amount of data in bytes to fetch at a time when retrieving
|
||||
BLOB/CLOB data, defaults to 4096 bytes when not explicitly set.</entry>
|
||||
</row>
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</informaltable>
|
||||
</para>
|
||||
<para>
|
||||
<example>
|
||||
<title><function>ingres_connect</function> example</title>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.6 $ -->
|
||||
<!-- $Revision: 1.7 $ -->
|
||||
<section id="ingres.configuration">
|
||||
&reftitle.runtime;
|
||||
&extension.runtime;
|
||||
|
@ -70,6 +70,24 @@
|
|||
<entry>PHP_INI_ALL</entry>
|
||||
<entry>Available since version 1.2.0 of the PECL extension.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>ingres.trace_connect</entry>
|
||||
<entry>"0"</entry>
|
||||
<entry>PHP_INI_ALL</entry>
|
||||
<entry>Available since version 1.3.1 of the PECL extension.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>ingres.timeout</entry>
|
||||
<entry>"-1"</entry>
|
||||
<entry>PHP_INI_ALL</entry>
|
||||
<entry>Available since version 1.3.1 of the PECL extension.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>ingres.array_index_start</entry>
|
||||
<entry>"1"</entry>
|
||||
<entry>PHP_INI_ALL</entry>
|
||||
<entry>Available since version 1.3.1 of the PECL extension.</entry>
|
||||
</row>
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</table>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.9 $ -->
|
||||
<!-- $Revision: 1.10 $ -->
|
||||
<!-- Purpose: database.vendors -->
|
||||
<!-- Membership: pecl, external -->
|
||||
|
||||
|
@ -30,8 +30,8 @@
|
|||
<section id="ingres.requirements">
|
||||
&reftitle.required;
|
||||
<para>
|
||||
To compile PHP with Ingres support, you need the Open API library
|
||||
and header files included with Ingres II.
|
||||
To compile PHP with Ingres support, you need the Ingres OpenAPI library
|
||||
and header files.
|
||||
</para>
|
||||
</section>
|
||||
|
||||
|
@ -46,6 +46,48 @@
|
|||
|
||||
&reference.ingres-ii.constants;
|
||||
|
||||
<section 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($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;
|
||||
|
|
Loading…
Reference in a new issue