mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-20 19:08:54 +00:00

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@61864 c90b9560-bf6c-de11-be94-00142212c4b1
1581 lines
50 KiB
XML
1581 lines
50 KiB
XML
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
<!-- $Revision: 1.17 $ -->
|
|
<reference id="ref.dbplus">
|
|
<title>DB++ Functions</title>
|
|
<titleabbrev>DB++</titleabbrev>
|
|
|
|
<partintro>
|
|
&warn.experimental;
|
|
|
|
<section id="dbplus.intro">
|
|
<title>DB++ Database Functions</title>
|
|
<para>
|
|
db++, made by the german company <ulink
|
|
url="&url.dbplus.company;">Concept asa</ulink>, is a relational
|
|
database system with high performance and low memory and disk
|
|
usage in mind. While providing SQL as an additional language
|
|
interface it is not really a SQL database in the first place but
|
|
provides its own AQL query language which is much more influenced
|
|
by the relational algebra then SQL is.
|
|
</para>
|
|
<para>
|
|
Concept asa always had an interest in supporting open source
|
|
languages, db++ has had Perl and Tcl call interfaces for years
|
|
now and uses Tcl as its internal stored procedure language.
|
|
</para>
|
|
</section>
|
|
|
|
<section id="dbplus.requirenments">
|
|
<title>Requirements</title>
|
|
<para>
|
|
You need the developement libraries and header files included in
|
|
every db++ installaion archive. <ulink
|
|
url="&url.dbplus.company;">Concept asa</ulink> provides
|
|
additional <ulink
|
|
url="&url.dbplus.documentation;">documentation</ulink> and <ulink
|
|
url="&url.dbplus.download;">Demo versions</ulink> of db++ for
|
|
Linux, some other UNIX versions and Windows95/NT.
|
|
</para>
|
|
</section>
|
|
|
|
<section id="dbplus.installation">
|
|
<title>Installation</title>
|
|
<para>
|
|
Creation and installation of this extension requires the db++
|
|
client libraries and header files to be installed on your system.
|
|
You have to run <command>configure</command> with option
|
|
<option>--with-dbplus</option> to build this extension.
|
|
</para>
|
|
<para>
|
|
<command>configure</command> looks for the client libraries and
|
|
header files under the default pathes
|
|
<filename>/usr/dbplus</filename>,
|
|
<filename>/usr/local/dbplus</filename> and
|
|
<filename>/opt/dblus</filename>. If you have installed db++ in a
|
|
different place you have add the installation path to the
|
|
<command>configure</command> option like 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>Create() 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">
|
|
<refnamediv>
|
|
<refname>dbplus_add</refname>
|
|
<refpurpose>Add a tuple to a relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_add</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>tuple</parameter></paramdef>
|
|
</funcprototype>
|
|
</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>
|
|
|
|
<refentry id="function.dbplus-aql">
|
|
<refnamediv>
|
|
<refname>dbplus_aql</refname>
|
|
<refpurpose>Perform AQL query</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_aql</function></funcdef>
|
|
<paramdef>string <parameter>query</parameter></paramdef>
|
|
<paramdef>string
|
|
<parameter><optional>server</optional></parameter>
|
|
</paramdef>
|
|
<paramdef>string
|
|
<parameter><optional>dbpath</optional></parameter>
|
|
</paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_aql</function> will execute an AQL
|
|
<parameter>query</parameter> on the given
|
|
<parameter>server</parameter> and
|
|
<parameter>dbpath</parameter>.
|
|
</para>
|
|
<para>
|
|
On success it will return a relation handle. The result data may
|
|
be fetched from this relation by calling
|
|
<function>dbplus_next</function> and
|
|
<function>dbplus_current</function>. Other relation access
|
|
functions will not work on a result relation.
|
|
</para>
|
|
<para>
|
|
Further information on the AQL A... Query Language is provided in
|
|
the opriginal db++ manual.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-chdir">
|
|
<refnamediv>
|
|
<refname>dbplus_chdir</refname>
|
|
<refpurpose>Get/Set database virtual current directory</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>string <function>dbplus_chdir</function></funcdef>
|
|
<paramdef>string
|
|
<parameter><optional>newdir</optional></parameter>
|
|
</paramdef>
|
|
</funcprototype>
|
|
</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>
|
|
|
|
<refentry id="function.dbplus-close">
|
|
<refnamediv>
|
|
<refname>dbplus_close</refname>
|
|
<refpurpose>Close a relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_close</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Calling <function>dbplus_close</function> will close a relation
|
|
previously opened by <function>dbplus_open</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-curr">
|
|
<refnamediv>
|
|
<refname>dbplus_curr</refname>
|
|
<refpurpose>Get current tuple from relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_curr</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>tuple</parameter></paramdef>
|
|
</funcprototype>
|
|
</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>
|
|
|
|
<refentry id="function.dbplus-errcode">
|
|
<refnamediv>
|
|
<refname>dbplus_errcode</refname>
|
|
<refpurpose>
|
|
Get error string for given errorcode or last error
|
|
</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>string <function>dbplus_errcode</function></funcdef>
|
|
<paramdef>int <parameter>errno</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_errcode</function> returns a cleartext error
|
|
string for the error code passed as <parameter>errno</parameter>
|
|
of for the result code of the last db++ operation if no parameter
|
|
is given.
|
|
</para>
|
|
</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>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_errno</function> will return the error code
|
|
returned by the last db++ operation.
|
|
</para>
|
|
<para>
|
|
See also <function>dbplus_errcode</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-find">
|
|
<refnamediv>
|
|
<refname>dbplus_find</refname>
|
|
<refpurpose>Set a constraint on a relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_find</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>constraints</parameter></paramdef>
|
|
<paramdef>mixed <parameter>tuple</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_find</function> will place a constraint on the
|
|
given relation. Further calls to functions like
|
|
<function>dbplus_curr</function> or
|
|
<function>dbplus_next</function> will only return tuples matching
|
|
the given constraints.
|
|
</para>
|
|
<para>
|
|
Constraints are triplets of strings containing of a domain name,
|
|
a comparison operator and a comparison value. The
|
|
<parameter>constraints</parameter> parameter array may consist of
|
|
a collection of string arrays, each of which contains a domain, an
|
|
operator and a value, or of a single string array containing a
|
|
multiple of three elements.
|
|
</para>
|
|
<para>
|
|
The comparison operator may be one of the following strings:
|
|
'==', '>', '>=', '<', '<=', '!=', '~' for a regular
|
|
expression match and 'BAND' or 'BOR' for bitwise operations.
|
|
</para>
|
|
<para>
|
|
See also <function>dbplus_unselect</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-first">
|
|
<refnamediv>
|
|
<refname>dbplus_first</refname>
|
|
<refpurpose>Get first tuple from relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_first</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>tuple</parameter></paramdef>
|
|
</funcprototype>
|
|
</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_curr</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>Flush all changes made on a relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_flush</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</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>
|
|
|
|
<refentry id="function.dbplus-freealllocks">
|
|
<refnamediv>
|
|
<refname>dbplus_freealllocks</refname>
|
|
<refpurpose>Free all locks held by this client</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_freealllocks</function></funcdef>
|
|
<void/>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_freeaalllocks</function> will free all tuple locks
|
|
held by this client.
|
|
</para>
|
|
<para>
|
|
See also <function>dbplus_getlock</function>,
|
|
<function>dbplus_freelock</function>, and
|
|
<function>dbplus_freerlocks</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-freelock">
|
|
<refnamediv>
|
|
<refname>dbplus_freelock</refname>
|
|
<refpurpose>Release write lock on tuple</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_freelock</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>string <parameter>tname</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_freelock</function> will release a write lock on
|
|
the given <parameter>tuple</parameter> previously obtained by
|
|
<function>dbplus_getlock</function>.
|
|
</para>
|
|
<para>
|
|
See also <function>dbplus_getlock</function>,
|
|
<function>dbplus_freerlocks</function>, and
|
|
<function>dbplus_freealllocks</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-freerlocks">
|
|
<refnamediv>
|
|
<refname>dbplus_freerlocks</refname>
|
|
<refpurpose>Free all tuple locks on given relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_freerlocks</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_freerlocks</function> will free all tuple locks held
|
|
on the given <parameter>relation</parameter>.
|
|
</para>
|
|
<para>
|
|
See also <function>dbplus_getlock</function>,
|
|
<function>dbplus_freelock</function>, and
|
|
<function>dbplus_freealllocks</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-getlock">
|
|
<refnamediv>
|
|
<refname>dbplus_getlock</refname>
|
|
<refpurpose>Get a write lock on a tuple</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_getlock</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>string <parameter>tname</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<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>
|
|
|
|
<refentry id="function.dbplus-getunique">
|
|
<refnamediv>
|
|
<refname>dbplus_getunique</refname>
|
|
<refpurpose>Get a id number unique to a relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_getunique</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>int <parameter>uniqueid</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<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>
|
|
|
|
<refentry id="function.dbplus-info">
|
|
<refnamediv>
|
|
<refname>dbplus_info</refname>
|
|
<refpurpose>???</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_info</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>string <parameter>key</parameter></paramdef>
|
|
<paramdef>array <parameter></parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Not implemented yet.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-last">
|
|
<refnamediv>
|
|
<refname>dbplus_last</refname>
|
|
<refpurpose>Get last tuple from relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_last</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>tuple</parameter></paramdef>
|
|
</funcprototype>
|
|
</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_curr</function>,
|
|
<function>dbplus_prev</function>, and
|
|
<function>dbplus_next</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-lockrel">
|
|
<refnamediv>
|
|
<refname>dbplus_lockrel</refname>
|
|
<refpurpose>Request write lock on relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_lockrel</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_lockrel</function> will request a write lock
|
|
on the given relation. Other clients may still query the
|
|
relation, but can't alter it while it is locked.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-next">
|
|
<refnamediv>
|
|
<refname>dbplus_next</refname>
|
|
<refpurpose>Get next tuple from relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_next</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter></parameter></paramdef>
|
|
</funcprototype>
|
|
</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_curr</function>,
|
|
<function>dbplus_prev</function>, and
|
|
<function>dbplus_last</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-open">
|
|
<refnamediv>
|
|
<refname>dbplus_open</refname>
|
|
<refpurpose>Open relation file</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_open</function></funcdef>
|
|
<paramdef>string <parameter>name</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
The relation file <parameter>name</parameter> will be opened.
|
|
<parameter>name</parameter> can be either a file name or a
|
|
relative or absolute path name. This will be mapped in any case
|
|
to an absolute relation file path on a specific host machine and
|
|
server.
|
|
</para>
|
|
<para>
|
|
On success a relation file resource (cursor) is returned which must
|
|
be used in any subsequent commanads referencing the relation.
|
|
Failure leads to a zero return value, the actual error code may
|
|
be asked for by calling <function>dbplus_errno</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-prev">
|
|
<refnamediv>
|
|
<refname>dbplus_prev</refname>
|
|
<refpurpose>Get previous tuple from relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_prev</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>tuple</parameter></paramdef>
|
|
</funcprototype>
|
|
</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_curr</function>,
|
|
<function>dbplus_next</function>, and
|
|
<function>dbplus_last</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rchperm">
|
|
<refnamediv>
|
|
<refname>dbplus_rchperm</refname>
|
|
<refpurpose>Change relation permissions</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_rchperm</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>int <parameter>mask</parameter></paramdef>
|
|
<paramdef>string <parameter>user</parameter></paramdef>
|
|
<paramdef>string <parameter>group</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rchperm</function> will change access
|
|
permissions as specified by <parameter>mask</parameter>,
|
|
<parameter>user</parameter> and <parameter>group</parameter>. The
|
|
values for these are operating system specific.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rcreate">
|
|
<refnamediv>
|
|
<refname>dbplus_rcreate</refname>
|
|
<refpurpose></refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_rcreate</function></funcdef>
|
|
<paramdef>string <parameter>name</parameter></paramdef>
|
|
<paramdef>mixed <parameter>domlist</parameter></paramdef>
|
|
<paramdef>boolean <parameter><optional>overwrite</optional></parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rcreate</function> will create a new relation
|
|
named <parameter>name</parameter>. An existing relation by the
|
|
same name will only be overwritten if the relation is currently
|
|
not in use and <parameter>overwrite</parameter> is set to TRUE.
|
|
</para>
|
|
<para>
|
|
<parameter>domlist</parameter> should contain the domain
|
|
specification for the new relation within an array of domain
|
|
description strings. ( <function>dbplus_rcreate</function> will
|
|
also accept a string with space delimited domain description
|
|
strings, but it is recommended to use an array). A domain
|
|
description string consists of a domain name unique to this
|
|
relation, a slash and a type specification character. See the
|
|
db++ documentatiion, especially the dbcreate(1) manpage, for a
|
|
description of available type specifiers and their meanings.
|
|
</para>
|
|
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rcrtexact">
|
|
<refnamediv>
|
|
<refname>dbplus_rcrtexact</refname>
|
|
<refpurpose></refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_rcrtexact</function></funcdef>
|
|
<paramdef>string <parameter>name</parameter></paramdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>boolean <parameter>overwrite</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rcrtexact</function> will create an exact but
|
|
empty copy of the given <parameter>relation</parameter> under a
|
|
new <parameter>name</parameter>. An existing relation by the same
|
|
<parameter>name</parameter> will only be overwritten if
|
|
<parameter>overwrite</parameter> is TRUE and no other process is
|
|
currently using the relation.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rcrtlike">
|
|
<refnamediv>
|
|
<refname>dbplus_rcrtlike</refname>
|
|
<refpurpose></refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_rcrtlike</function></funcdef>
|
|
<paramdef>string <parameter>name</parameter></paramdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>int <parameter>flag</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rcrtexact</function> will create an empty copy
|
|
of the given <parameter>relation</parameter> under a new
|
|
<parameter>name</parameter>, but with default indices. An
|
|
existing relation by the same <parameter>name</parameter> will
|
|
only be overwritten if <parameter>overwrite</parameter> is TRUE
|
|
and no other process is currently using the relation.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-resolve">
|
|
<refnamediv>
|
|
<refname>dbplus_resolve</refname>
|
|
<refpurpose>Resolve host information for relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_resolve</function></funcdef>
|
|
<paramdef>string <parameter>relation_name</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_resolve</function> will try to resolve the given
|
|
<parameter>relation_name</parameter> and find out internal server
|
|
id, real hostname and the database path on this host. The
|
|
function will return an array containing these values under the
|
|
keys 'sid', 'host' and 'host_path' or &false; on error.
|
|
</para>
|
|
<para>
|
|
See also <function>dbplus_tcl</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rkeys">
|
|
<refnamediv>
|
|
<refname>dbplus_rkeys</refname>
|
|
<refpurpose>Specify new primary key for a relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_rkeys</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>mixed <parameter>domlist</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rkeys</function> will replace the current
|
|
primary key for <parameter>relation</parameter> with the
|
|
combination of domains specified by <parameter>domlist</parameter>.
|
|
</para>
|
|
<para>
|
|
<parameter>domlist</parameter> may be passed as a single domain name
|
|
string or as an array of domain names.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-restorepos">
|
|
<refnamediv>
|
|
<refname>dbplus_restorepos</refname> <refpurpose>???</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_restorepos</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>tuple</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Not implemented yet.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-ropen">
|
|
<refnamediv>
|
|
<refname>dbplus_ropen</refname>
|
|
<refpurpose>Open relation file local</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_ropen</function></funcdef>
|
|
<paramdef>string <parameter>name</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_ropen</function> will open the relation
|
|
<parameter>file</parameter> localy for quick access without any
|
|
client/server overhead. Access is read only and only
|
|
<function>dbplus_current</function> and
|
|
<function>dbplus_next</function> may be applied to the returned
|
|
relation.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rquery">
|
|
<refnamediv>
|
|
<refname>dbplus_rquery</refname>
|
|
<refpurpose>Perform local (raw) AQL query</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_rquery</function></funcdef>
|
|
<paramdef>string <parameter>query</parameter></paramdef>
|
|
<paramdef>string <parameter>dbpath</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rquery</function> performs a local (raw) AQL
|
|
query using an AQL interpreter embedded into the db++ client
|
|
library. <function>dbplus_rquery</function> is faster than
|
|
<function>dbplus_aql</function> but will work on local data only.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rrename">
|
|
<refnamediv>
|
|
<refname>dbplus_rrename</refname>
|
|
<refpurpose>Rename a relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_rrename</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>string <parameter>name</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rrename</function> will change the name of
|
|
<parameter>relation</parameter> to <parameter>name</parameter>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rsecindex">
|
|
<refnamediv>
|
|
<refname>dbplus_rsecindex</refname>
|
|
<refpurpose>
|
|
Create a new secondary index for a relation
|
|
</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_rsecindex</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>mixed <parameter>domlist</parameter></paramdef>
|
|
<paramdef>int <parameter>type</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rsecindex</function> will create a new secondary
|
|
index for <parameter>relation</parameter> with consists of the
|
|
domains specified by <parameter>domlist</parameter> and is of
|
|
type <parameter>type</parameter>
|
|
</para>
|
|
<para>
|
|
<parameter>domlist</parameter> may be passed as a single domain name
|
|
string or as an array of domain names.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-runlink">
|
|
<refnamediv>
|
|
<refname>dbplus_runlink</refname>
|
|
<refpurpose>Remove relation from filesystem</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_runlink</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_unlink</function> will close and remove the
|
|
<parameter>relation</parameter>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-rzap">
|
|
<refnamediv>
|
|
<refname>dbplus_rzap</refname>
|
|
<refpurpose>Remove all tuples from relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_rzap</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_rzap</function> will remove all tuples from
|
|
<parameter>relation</parameter>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-savepos">
|
|
<refnamediv>
|
|
<refname>dbplus_savepos</refname>
|
|
<refpurpose>???</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_savepos</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Not implemented yet.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-setindex">
|
|
<refnamediv>
|
|
<refname>dbplus_setindex</refname>
|
|
<refpurpose>???</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_setindex</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>string <parameter>idx_name</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Not implemented yet.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-setindexbynumber">
|
|
<refnamediv>
|
|
<refname>dbplus_setindexbynumber</refname>
|
|
<refpurpose>???</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int
|
|
<function>dbplus_setindexbynumber</function>
|
|
</funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>int <parameter>idx_number</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Not implemented yet.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-sql">
|
|
<refnamediv>
|
|
<refname>dbplus_sql</refname>
|
|
<refpurpose>Perform SQL query</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>resource <function>dbplus_sql</function></funcdef>
|
|
<paramdef>string <parameter>query</parameter></paramdef>
|
|
<paramdef>string <parameter>server</parameter></paramdef>
|
|
<paramdef>string <parameter>dbpath</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Not implemented yet.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-tcl">
|
|
<refnamediv>
|
|
<refname>dbplus_tcl</refname>
|
|
<refpurpose>Execute TCL code on server side</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_tcl</function></funcdef>
|
|
<paramdef>int <parameter>sid</parameter></paramdef>
|
|
<paramdef>string <parameter>script</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
A db++ server will prepare a TCL interpreter for each client
|
|
connection. This interpreter will enable the server to execute
|
|
TCL code provided by the client as a sort of stored procedures to
|
|
improve the performance of database operations by avoiding
|
|
client/server data transfers and context switches.
|
|
</para>
|
|
<para>
|
|
<function>dbplus_tcl</function> needs to pass the client
|
|
connection id the TCL <parameter>script</parameter> code should
|
|
be executed by. <function>dbplus_resolve</function> will provide
|
|
this connection id. The function will return whatever the TCL
|
|
code returns or a TCL error message if the TCL code fails.
|
|
</para>
|
|
<para>
|
|
See also <function>dbplus_resolve</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-tremove">
|
|
<refnamediv>
|
|
<refname>dbplus_tremove</refname>
|
|
<refpurpose>Remove tuple and return new current tuple</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_tremove</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>tuple</parameter></paramdef>
|
|
<paramdef>array
|
|
<parameter><optional>current</optional></parameter>
|
|
</paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_tremove</function> removes
|
|
<parameter>tuple</parameter> from <parameter>relation</parameter>
|
|
if it perfectly matches a tuple within the
|
|
relation. <parameter>current</parameter>, if given, will contain
|
|
the data of the new current tuple after calling
|
|
<function>dbplus_tremove</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-undo">
|
|
<refnamediv>
|
|
<refname>dbplus_undo</refname>
|
|
<refpurpose>???</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_undo</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Not implemented yet.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-undoprepare">
|
|
<refnamediv>
|
|
<refname>dbplus_undoprepare</refname>
|
|
<refpurpose>???</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_undoprepare</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Not implemented yet.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-unlockrel">
|
|
<refnamediv>
|
|
<refname>dbplus_unlockrel</refname>
|
|
<refpurpose>Give up write lock on relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_unlockrel</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_unlockrel</function> will release a write lock
|
|
previously obtained by <function>dbplus_lockrel</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-unselect">
|
|
<refnamediv>
|
|
<refname>dbplus_unselect</refname>
|
|
<refpurpose>Remove a constraint from relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_unselect</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
Calling <function>dbplus_unselect</function> will remove a
|
|
constraint previously set by <function>dbplus_find</function> on
|
|
<parameter>relation</parameter>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-update">
|
|
<refnamediv>
|
|
<refname>dbplus_update</refname>
|
|
<refpurpose>Update specified tuple in relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_update</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
<paramdef>array <parameter>old</parameter></paramdef>
|
|
<paramdef>array <parameter>new</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_update</function> replaces the tuple given by
|
|
<parameter>old</parameter> with the data from
|
|
<parameter>new</parameter> if and only if
|
|
<parameter>old</parameter> completely matches a tuple within
|
|
<parameter>relation</parameter>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-xlockrel">
|
|
<refnamediv>
|
|
<refname>dbplus_xlockrel</refname>
|
|
<refpurpose>Request exclusive lock on relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_xlockrel</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_xlockrel</function> will request an exclusive
|
|
lock on <parameter>relation</parameter> preventing even read
|
|
access from other clients.
|
|
</para>
|
|
<para>
|
|
See also <function>dbplus_xunlockrel</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<refentry id="function.dbplus-xunlockrel">
|
|
<refnamediv>
|
|
<refname>dbplus_xunlockrel</refname>
|
|
<refpurpose>Free exclusive lock on relation</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>int <function>dbplus_xunlockrel</function></funcdef>
|
|
<paramdef>resource <parameter>relation</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
&warn.experimental.func;
|
|
<para>
|
|
<function>dbplus_xunlockrel</function> will release an exclusive
|
|
lock on <parameter>relation</parameter> previously obtained by
|
|
<function>dbplus_xlockrel</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
|
|
</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
|
|
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
|
|
-->
|