mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
some additions, still some way to go ...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@55678 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
8f46acc689
commit
047cba3421
1 changed files with 375 additions and 8 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.4 $ -->
|
||||
<!-- $Revision: 1.5 $ -->
|
||||
<reference id="ref.dbplus">
|
||||
<title>DB++ functions</title>
|
||||
<titleabbrev></titleabbrev>
|
||||
|
@ -42,7 +42,220 @@
|
|||
this: <option>--with-dbplus=/your/installation/path</option>.
|
||||
</para>
|
||||
</section>
|
||||
|
||||
<section id="dbplus.errorcodes">
|
||||
<title>db++ error codes</title>
|
||||
<para>
|
||||
<table>
|
||||
<title>db++ error codes</title>
|
||||
<tgroup cols="3">
|
||||
<thead>
|
||||
<row>
|
||||
<entry>PHP Constant</entry>
|
||||
<entry>db++ constant</entry>
|
||||
<entry>meaning</entry>
|
||||
</row>
|
||||
</thead>
|
||||
<tbody>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_NOERR</entry>
|
||||
<entry>ERR_NOERR</entry>
|
||||
<entry>Null error condition</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_DUPLICATE</entry>
|
||||
<entry>ERR_DUPLICATE</entry>
|
||||
<entry>Tried to insert a duplicate tuple</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_EOSCAN</entry>
|
||||
<entry>ERR_EOSCAN</entry>
|
||||
<entry>End of scan from rget()</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_EMPTY</entry>
|
||||
<entry>ERR_EMPTY</entry>
|
||||
<entry>Relation is empty (server)</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_CLOSE</entry>
|
||||
<entry>ERR_CLOSE</entry>
|
||||
<entry>The server can't close</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_WLOCKED</entry>
|
||||
<entry>ERR_WLOCKED</entry>
|
||||
<entry>The record is write locked</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_LOCKED</entry>
|
||||
<entry>ERR_LOCKED</entry>
|
||||
<entry>Relation was already locked</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_NOLOCK</entry>
|
||||
<entry>ERR_NOLOCK</entry>
|
||||
<entry>Relation cannot be locked</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_READ</entry>
|
||||
<entry>ERR_READ</entry>
|
||||
<entry>Read error on relation</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_WRITE</entry>
|
||||
<entry>ERR_WRITE</entry>
|
||||
<entry>Write error on relation</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_CREATE</entry>
|
||||
<entry>ERR_CREATE</entry>
|
||||
<entry>Creat() system call failed</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_LSEEK</entry>
|
||||
<entry>ERR_LSEEK</entry>
|
||||
<entry>Lseek() system call failed</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_LENGTH</entry>
|
||||
<entry>ERR_LENGTH</entry>
|
||||
<entry>Tuple exceeds maximum length</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_OPEN</entry>
|
||||
<entry>ERR_OPEN</entry>
|
||||
<entry>Open() system call failed</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_WOPEN</entry>
|
||||
<entry>ERR_WOPEN</entry>
|
||||
<entry>Relation already opened for writing</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_MAGIC</entry>
|
||||
<entry>ERR_MAGIC</entry>
|
||||
<entry>File is not a relation</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_VERSION</entry>
|
||||
<entry>ERR_VERSION</entry>
|
||||
<entry>File is a very old relation</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_PGSIZE</entry>
|
||||
<entry>ERR_PGSIZE</entry>
|
||||
<entry>Relation uses a different page size</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_CRC</entry>
|
||||
<entry>ERR_CRC</entry>
|
||||
<entry>Invalid crc in the superpage</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_PIPE</entry>
|
||||
<entry>ERR_PIPE</entry>
|
||||
<entry>Piped relation requires lseek()</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_NIDX</entry>
|
||||
<entry>ERR_NIDX</entry>
|
||||
<entry>Too many secondary indices</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_MALLOC</entry>
|
||||
<entry>ERR_MALLOC</entry>
|
||||
<entry>Malloc() call failed</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_NUSERS</entry>
|
||||
<entry>ERR_NUSERS</entry>
|
||||
<entry>Error use of max users</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_PREEXIT</entry>
|
||||
<entry>ERR_PREEXIT</entry>
|
||||
<entry>Caused by invalid usage</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_ONTRAP</entry>
|
||||
<entry>ERR_ONTRAP</entry>
|
||||
<entry>Caused by a signal</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_PREPROC</entry>
|
||||
<entry>ERR_PREPROC</entry>
|
||||
<entry>Error in the preprocessor</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_DBPARSE</entry>
|
||||
<entry>ERR_DBPARSE</entry>
|
||||
<entry>Error in the parser</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_DBRUNERR</entry>
|
||||
<entry>ERR_DBRUNERR</entry>
|
||||
<entry>Run error in db</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_DBPREEXIT</entry>
|
||||
<entry>ERR_DBPREEXIT</entry>
|
||||
<entry>Exit condition caused by prexit() * procedure</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_WAIT</entry>
|
||||
<entry>ERR_WAIT</entry>
|
||||
<entry>Wait a little (Simple only)</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_CORRUPT_TUPLE</entry>
|
||||
<entry>ERR_CORRUPT_TUPLE</entry>
|
||||
<entry>A client sent a corrupt tuple</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_WARNING0</entry>
|
||||
<entry>ERR_WARNING0</entry>
|
||||
<entry>The Simple routines encountered a non fatal error which was corrected</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_PANIC</entry>
|
||||
<entry>ERR_PANIC</entry>
|
||||
<entry>The server should not really die but after a disaster send ERR_PANIC to all its clients</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_FIFO</entry>
|
||||
<entry>ERR_FIFO</entry>
|
||||
<entry>Can't create a fifo</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_PERM</entry>
|
||||
<entry>ERR_PERM</entry>
|
||||
<entry>Permission denied</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_TCL</entry>
|
||||
<entry>ERR_TCL</entry>
|
||||
<entry>TCL_error</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_RESTRICTED</entry>
|
||||
<entry>ERR_RESTRICTED</entry>
|
||||
<entry>Only two users</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_USER</entry>
|
||||
<entry>ERR_USER</entry>
|
||||
<entry>An error in the use of the library by an application programmer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>DBPLUS_ERR_UNKNOWN</entry>
|
||||
<entry>ERR_UNKNOWN</entry>
|
||||
<entry></entry>
|
||||
</row>
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</table>
|
||||
</para>
|
||||
</section>
|
||||
</partintro>
|
||||
|
||||
<refentry id="function.dbplus-add">
|
||||
|
@ -61,7 +274,20 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
This function will add a tuple to a relation. The
|
||||
<parameter>tuple</parameter> data is an array of attribute/value
|
||||
pairs to be inserted into the given
|
||||
<parameter>relation</parameter>. After successfull execution the
|
||||
<parameter>tuple</parameter> array will contain the complete data
|
||||
of the newly created tuple, including all implicitly set domain
|
||||
fields like sequences.
|
||||
</para>
|
||||
<para>
|
||||
The function will return zero (aka. DBPLUS_ERR_NOERR) on success
|
||||
or a db++ error code on failure. See
|
||||
<function>dbplus_errcode</function> or the introduction to this
|
||||
chapter for more information on db++ error codes.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
@ -107,6 +333,14 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_chdir</function> will change the virtual current
|
||||
directory where relation files will be looked for by
|
||||
<function>dbplus_open</function>.
|
||||
<function>dbplus_chdir</function> will return the absolute path
|
||||
of the current directory. Calling
|
||||
<function>dbplus_chdir</function> without giving any
|
||||
<parameter>newdir</parameter> may be used to query the current
|
||||
working directory.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
@ -126,6 +360,8 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
Calling <function>dbplus_close</function> will close a relation
|
||||
previously opened by <function>dbplus_open</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
@ -146,7 +382,23 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_curr</function> will read the data for the
|
||||
current tuple for the given <parameter>relation</parameter> and
|
||||
will pass it back as an associative array in
|
||||
<parameter>tuple</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
The function will return zero (aka. DBPLUS_ERR_NOERR) on success
|
||||
or a db++ error code on failure. See
|
||||
<function>dbplus_errcode</function> or the introduction to this
|
||||
chapter for more information on db++ error codes.
|
||||
</para>
|
||||
<para>
|
||||
See also <function>dbplus_first</function>,
|
||||
<function>dbplus_prev</function>,
|
||||
<function>dbplus_next</function>,
|
||||
and <function>dbplus_last</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
@ -169,6 +421,24 @@
|
|||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
<refentry id="function.dbplus-errno">
|
||||
<refnamediv>
|
||||
<refname>dbplus_errno</refname>
|
||||
<refpurpose>Get error code for last operation</refpurpose>
|
||||
</refnamediv>
|
||||
<refsect1>
|
||||
<title>Description</title>
|
||||
<funcsynopsis>
|
||||
<funcprototype>
|
||||
<funcdef>int <function>dbplus_errno</function></funcdef>
|
||||
<void/>
|
||||
</funcprototype>
|
||||
</funcsynopsis>
|
||||
<para>
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
<refentry id="function.dbplus-first">
|
||||
<refnamediv>
|
||||
<refname>dbplus_first</refname>
|
||||
|
@ -185,14 +455,30 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_curr</function> will read the data for the
|
||||
first tuple for the given <parameter>relation</parameter>, make
|
||||
it the current tuple and pass it back as an associative array in
|
||||
<parameter>tuple</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
The function will return zero (aka. DBPLUS_ERR_NOERR) on success
|
||||
or a db++ error code on failure. See
|
||||
<function>dbplus_errcode</function> or the introduction to this
|
||||
chapter for more information on db++ error codes.
|
||||
</para>
|
||||
<para>
|
||||
See also <function>dbplus_current</function>,
|
||||
<function>dbplus_prev</function>,
|
||||
<function>dbplus_next</function>,
|
||||
and <function>dbplus_last</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
<refentry id="function.dbplus-flush">
|
||||
<refnamediv>
|
||||
<refname>dbplus_flush</refname>
|
||||
<refpurpose>???</refpurpose>
|
||||
<refpurpose>Flush all changes made on a relation</refpurpose>
|
||||
</refnamediv>
|
||||
<refsect1>
|
||||
<title>Description</title>
|
||||
|
@ -204,7 +490,15 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_flush</function> will write all changes applied
|
||||
to <parameter>relation</parameter> since the last flush to disk.
|
||||
</para>
|
||||
<para>
|
||||
The function will return zero (aka. DBPLUS_ERR_NOERR) on success
|
||||
or a db++ error code on failure. See
|
||||
<function>dbplus_errcode</function> or the introduction to this
|
||||
chapter for more information on db++ error codes.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
@ -223,6 +517,8 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_freeaalllocks</function> will free all locks held
|
||||
by this client.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
@ -242,6 +538,8 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_freerlocks</function> will free all locks held
|
||||
on the given <parameter>relation</parameter>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
@ -283,7 +581,23 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_curr</function> will read the data for the
|
||||
last tuple for the given <parameter>relation</parameter>, make
|
||||
it the current tuple and pass it back as an associative array in
|
||||
<parameter>tuple</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
The function will return zero (aka. DBPLUS_ERR_NOERR) on success
|
||||
or a db++ error code on failure. See
|
||||
<function>dbplus_errcode</function> or the introduction to this
|
||||
chapter for more information on db++ error codes.
|
||||
</para>
|
||||
<para>
|
||||
See also <function>dbplus_first</function>,
|
||||
<function>dbplus_current</function>,
|
||||
<function>dbplus_prev</function>,
|
||||
and <function>dbplus_next</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
@ -322,7 +636,24 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_curr</function> will read the data for the
|
||||
next tuple for the given <parameter>relation</parameter>, will
|
||||
make it the current tuple and
|
||||
will pass it back as an associative array in
|
||||
<parameter>tuple</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
The function will return zero (aka. DBPLUS_ERR_NOERR) on success
|
||||
or a db++ error code on failure. See
|
||||
<function>dbplus_errcode</function> or the introduction to this
|
||||
chapter for more information on db++ error codes.
|
||||
</para>
|
||||
<para>
|
||||
See also <function>dbplus_first</function>,
|
||||
<function>dbplus_current</function>,
|
||||
<function>dbplus_prev</function>,
|
||||
and <function>dbplus_last</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
@ -370,7 +701,24 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
<function>dbplus_curr</function> will read the data for the
|
||||
next tuple for the given <parameter>relation</parameter>, will
|
||||
make it the current tuple and
|
||||
will pass it back as an associative array in
|
||||
<parameter>tuple</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
The function will return zero (aka. DBPLUS_ERR_NOERR) on success
|
||||
or a db++ error code on failure. See
|
||||
<function>dbplus_errcode</function> or the introduction to this
|
||||
chapter for more information on db++ error codes.
|
||||
</para>
|
||||
<para>
|
||||
See also <function>dbplus_first</function>,
|
||||
<function>dbplus_current</function>,
|
||||
<function>dbplus_next</function>,
|
||||
and <function>dbplus_last</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
@ -753,7 +1101,9 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
Not implemented yet.
|
||||
<function>dbplus_freelock</function> will release a write lock on
|
||||
the given <parameter>tuple</parameter> previously obtained by
|
||||
<function>dbplus_getlock</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
@ -774,8 +1124,17 @@
|
|||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
Not implemented yet.
|
||||
<function>dbplus_getlock</function> will request a write lock on
|
||||
the speified <parameter>tuple</parameter>. It will return zero
|
||||
on success or a non-zero error code, especially
|
||||
DBPLUS_ERR_WLOCKED, on failure.
|
||||
</para>
|
||||
<para>
|
||||
See also
|
||||
<function>dbplus_freelock</function>,
|
||||
<function>dbplus_freerlocks</function>,
|
||||
and <function>dbplus_freealllocks</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
@ -790,14 +1149,22 @@
|
|||
<funcprototype>
|
||||
<funcdef>int <function>dbplus_getunique</function></funcdef>
|
||||
<paramdef>int <parameter>handle</parameter></paramdef>
|
||||
<paramdef>string <parameter>varname</parameter></paramdef>
|
||||
<paramdef>int <parameter>flush</parameter></paramdef>
|
||||
<paramdef>int <parameter>uniqueid</parameter></paramdef>
|
||||
</funcprototype>
|
||||
</funcsynopsis>
|
||||
&warn.experimental.func;
|
||||
<para>
|
||||
Not implemented yet.
|
||||
<function>dbplus_getunique</function> will obtain a number
|
||||
guaranteed to be unique for the given
|
||||
<parameter>relation</parameter> and will pass it back in the
|
||||
variable given as <parameter>uniqueid</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
The function will return zero (aka. DBPLUS_ERR_NOERR) on success
|
||||
or a db++ error code on failure. See
|
||||
<function>dbplus_errcode</function> or the introduction to this
|
||||
chapter for more information on db++ error codes.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
|
Loading…
Reference in a new issue