mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
solved:
- tab issue - empty configure.xml issue - example.xml short opening tags and PEAR CS git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@301890 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
98fcfd603a
commit
befe9b2375
46 changed files with 429 additions and 488 deletions
|
@ -1,76 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V5.0//EN"
|
||||
"{PATH_TO_DOCBASE}/docbook/docbook-xml/docbook.dtd" [
|
||||
|
||||
<!-- $Revision$ -->
|
||||
<!-- We use xhtml entities all over the place -->
|
||||
<!ENTITY % xhtml-lat1 SYSTEM "{PATH_TO_DOCBASE}/entities/ISO/xhtml1-lat1.ent">
|
||||
<!ENTITY % xhtml-symbol SYSTEM "{PATH_TO_DOCBASE}/entities/ISO/xhtml1-symbol.ent">
|
||||
<!ENTITY % xhtml-special SYSTEM "{PATH_TO_DOCBASE}/entities/ISO/xhtml1-special.ent">
|
||||
<!ENTITY % isopub SYSTEM "{PATH_TO_DOCBASE}/entities/ISO/isopub.ent">
|
||||
%xhtml-lat1;
|
||||
%xhtml-symbol;
|
||||
%xhtml-special;
|
||||
%isopub;
|
||||
|
||||
<!-- Fallback to English definitions and snippets (in case of missing translation) -->
|
||||
<!ENTITY % language-defs.default SYSTEM "{PATH_TO_DOC}/language-defs.ent">
|
||||
<!ENTITY % language-snippets.default SYSTEM "{PATH_TO_DOC}/language-snippets.ent">
|
||||
<!ENTITY % extensions.default SYSTEM "{PATH_TO_DOC}/extensions.ent">
|
||||
|
||||
%language-defs.default;
|
||||
%extensions.default;
|
||||
%language-snippets.default;
|
||||
|
||||
<!-- All global entities for the XML files -->
|
||||
<!ENTITY % global.entities SYSTEM "{PATH_TO_DOCBASE}/entities/global.ent">
|
||||
|
||||
<!-- These are language independent -->
|
||||
<!ENTITY % frontpage.entities SYSTEM "{PATH_TO_DOC}/contributors.ent">
|
||||
<!ENTITY % file.entities SYSTEM "{PATH_TO_DOCBASE}/entities/file-entities.ent">
|
||||
|
||||
<!-- Include all external DTD parts defined previously -->
|
||||
%global.entities;
|
||||
%file.entities;
|
||||
%frontpage.entities;
|
||||
]>
|
||||
|
||||
<book xml:id="book.cubrid" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xml:lang="en">
|
||||
<title>Cubrid</title>
|
||||
<titleabbrev>Cubrid</titleabbrev>
|
||||
|
||||
<preface xml:id="intro.cubrid">
|
||||
&reftitle.intro;
|
||||
<para>
|
||||
|
||||
</para>
|
||||
</preface>
|
||||
|
||||
&reference.cubrid.setup;
|
||||
&reference.cubrid.constants;
|
||||
&reference.cubrid.examples;
|
||||
&reference.cubrid.reference;
|
||||
|
||||
</book>
|
||||
|
||||
<!-- 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
|
||||
-->
|
||||
|
|
@ -8,10 +8,10 @@
|
|||
<preface xml:id="intro.cubrid">
|
||||
&reftitle.intro;
|
||||
<para>
|
||||
These functions allow you to access CUBRID database servers. More information about CUBRID can be found at <link xlink:href="&url.cubrid;">CUBRID</link>.
|
||||
These functions allow you to access CUBRID database servers. More information about CUBRID can be found at <link xlink:href="&url.cubrid;">CUBRID</link>.
|
||||
</para>
|
||||
<para>
|
||||
Documentation for CUBRID can be found at <link xlink:href="&url.cubrid.docs;">CUBRID Documentation</link>.
|
||||
Documentation for CUBRID can be found at <link xlink:href="&url.cubrid.docs;">CUBRID Documentation</link>.
|
||||
</para>
|
||||
|
||||
</preface>
|
||||
|
|
|
@ -2,12 +2,54 @@
|
|||
<!-- $Revision$ -->
|
||||
|
||||
<section xml:id="cubrid.installation" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
&reftitle.install;
|
||||
|
||||
|
||||
<para>
|
||||
|
||||
</para>
|
||||
&reftitle.install;
|
||||
<para>
|
||||
From the CUBRID homepage (<link xlink:href="&url.cubrid;">CUBRID</link>), download the PHP module.
|
||||
</para>
|
||||
<section>
|
||||
<title>Installing PHP for Windows</title>
|
||||
<para>
|
||||
Create a directory named CUBRID in the directory where PHP is installed, and then copy the <parameter>cubrid_err.msg</parameter> file and the .dll file of the cubrid_php version you just downloaded. If you download CUBRID PHP version 5.1.4, add required settings as shown in the example below by editing the php.ini file.
|
||||
</para>
|
||||
<programlisting>
|
||||
<![CDATA[
|
||||
extension_dir=C:\PHP\CUBRID
|
||||
extension=cubrid_php5.1.4.dll
|
||||
[CUBRID]
|
||||
cubrid.err_path=C:\PHP\CUBRID
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
Once the configuration is complete, restart the web server. If you can see the CUBRID information as shown below when you check the PHP configuration using the phpinfo() function of PHP, it means that the installation was successful.
|
||||
</para>
|
||||
</section>
|
||||
<section xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<title>Installing PHP for Linux</title>
|
||||
<para>
|
||||
Unlike Windows, Linux provides its source code. Download the source code from the CUBRID homepage (<link xlink:href="&url.cubrid;">CUBRID</link>), and install it by following the INSTALL file of the compressed file. Also in the Linux version, edit and save the php.ini file, and then restart the web server.
|
||||
</para>
|
||||
<programlisting>
|
||||
<![CDATA[
|
||||
; Directory in which the loadable extensions (modules) reside.
|
||||
extension_dir = /usr/lib/php5/lib/php/ext
|
||||
extension=cubrid.so
|
||||
;for Windows, extension=cubrid.dll
|
||||
[CUBRID]
|
||||
cubrid.err_path=/home/cubrid/CUBRID/msg
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
Check the configuration using phpinfo() function.
|
||||
</para>
|
||||
<programlisting>
|
||||
<![CDATA[
|
||||
[root@localhost]#vi test.php
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
As with the Windows version of PHP, if you can see the CUBRID information on the web browser, it means that the installation was successful.
|
||||
</para>
|
||||
</section>
|
||||
|
||||
</section>
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to determine whether to get OID after query execution.
|
||||
Is used to determine whether to get OID after query execution.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -24,7 +24,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to execute the query in asynchronous mode.
|
||||
Is used to execute the query in asynchronous mode.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -35,7 +35,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to get the query result as a numeric array (0-default).
|
||||
Is used to get the query result as a numeric array (0-default).
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -46,7 +46,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to get the query result as an associative array.
|
||||
Is used to get the query result as an associative array.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -57,7 +57,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to get the query result as both numeric and associative arrays (default value).
|
||||
Is used to get the query result as both numeric and associative arrays (default value).
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -68,7 +68,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to get the query result an object that has the attribute whose name is the same as the column name.
|
||||
Is used to get the query result an object that has the attribute whose name is the same as the column name.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -79,7 +79,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to move the current cursor to the first position in the result.
|
||||
Is used to move the current cursor to the first position in the result.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -90,7 +90,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to move the current cursor as a default value if the origin is not specified.
|
||||
Is used to move the current cursor as a default value if the origin is not specified.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -101,7 +101,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is used to move the current cursor to the last position in the result.
|
||||
Is used to move the current cursor to the last position in the result.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -112,7 +112,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is the returned value of <function>cubrid_move_cursor</function> function in case of success.
|
||||
Is the returned value of <function>cubrid_move_cursor</function> function in case of success.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -123,7 +123,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is the returned value of <function>cubrid_move_cursor</function> function in case of failure.
|
||||
Is the returned value of <function>cubrid_move_cursor</function> function in case of failure.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -134,7 +134,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is the returned value of <function>cubrid_move_cursor</function> function in case of failure.
|
||||
Is the returned value of <function>cubrid_move_cursor</function> function in case of failure.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -145,7 +145,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -156,7 +156,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -167,7 +167,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -178,7 +178,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -189,7 +189,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -200,7 +200,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -211,7 +211,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -222,7 +222,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -233,7 +233,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -244,7 +244,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -255,7 +255,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -266,7 +266,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -277,7 +277,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -288,7 +288,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
Is a schema type used for <function>cubrid_schema</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -299,7 +299,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is the facility code of the occurred error code when using <function>cubrid_error_code_facility</function> function.
|
||||
Is the facility code of the occurred error code when using <function>cubrid_error_code_facility</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -310,7 +310,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is the facility code of the occurred error code when using <function>cubrid_error_code_facility</function> function.
|
||||
Is the facility code of the occurred error code when using <function>cubrid_error_code_facility</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -321,7 +321,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is the facility code of the occurred error code when using <function>cubrid_error_code_facility</function> function.
|
||||
Is the facility code of the occurred error code when using <function>cubrid_error_code_facility</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -332,7 +332,7 @@
|
|||
</term>
|
||||
<listitem>
|
||||
<simpara>
|
||||
Is the facility code of the occurred error code when using <function>cubrid_error_code_facility</function> function.
|
||||
Is the facility code of the occurred error code when using <function>cubrid_error_code_facility</function> function.
|
||||
</simpara>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
|
|
@ -5,126 +5,150 @@
|
|||
&reftitle.examples;
|
||||
<para>The following is a simple example that establishes a connection between PHP and CUBRID. This section will cover the most basic and notable features. The following code required to connect to CUBRID database, which means CUBRID Server and CUBRID Broker have to be running.</para>
|
||||
<para>The example below uses the demodb database as an examples. By default it is created during the installation. Make sure it has been created.</para>
|
||||
|
||||
|
||||
<example>
|
||||
<title>Example of Data Retrieval</title>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv='content-type' content='text/html; charset=euc-kr'>
|
||||
</head>
|
||||
<body>
|
||||
<center>
|
||||
<table border=2>
|
||||
<?
|
||||
// Set server information for CUBRID connection. host_ip is the IP
|
||||
// address where the CUBRID Broker is installed (localhost in this
|
||||
// example), and host_port is the port number of the CUBRID Broker.
|
||||
// The port number is the default given during the installation.
|
||||
// For details, see "Administrator's Guide."
|
||||
$host_ip = "localhost";
|
||||
$host_port = 33000;
|
||||
$db_name = "demodb";
|
||||
// Connect to CUBRID Server. Do not make the actual connection, but
|
||||
// only retain the connection information. The reason for not making
|
||||
// the actual connection is to handle transaction more efficiently
|
||||
// in the 3-tier architecture.
|
||||
$cubrid_con = @cubrid_connect($host_ip, $host_port, $db_name);
|
||||
<![CDATA[
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=euc-kr">
|
||||
</head>
|
||||
<body>
|
||||
<center>
|
||||
<table border=2>
|
||||
<?php
|
||||
/**
|
||||
* Set server information for CUBRID connection. host_ip is the IP
|
||||
* address where the CUBRID Broker is installed (localhost in this
|
||||
* example), and host_port is the port number of the CUBRID Broker.
|
||||
* The port number is the default given during the installation.
|
||||
* For details, see "Administrator's Guide."
|
||||
*/
|
||||
$host_ip = "localhost";
|
||||
$host_port = 33000;
|
||||
$db_name = "demodb";
|
||||
/**
|
||||
* Connect to CUBRID Server. Do not make the actual connection, but
|
||||
* only retain the connection information. The reason for not making
|
||||
* the actual connection is to handle transaction more efficiently
|
||||
* in the 3-tier architecture.
|
||||
*/
|
||||
$cubrid_con = @cubrid_connect($host_ip, $host_port, $db_name);
|
||||
|
||||
if (!$cubrid_con) {
|
||||
echo "Database Connection Error";
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
<?
|
||||
$sql = "select sports, count(players) as players from event group by sports";
|
||||
// Request the CUBRID Server for the results of the SQL statement.
|
||||
// Now make the actual connection to the CUBRID Server.
|
||||
$result = cubrid_execute($cubrid_con, $sql);
|
||||
if (!$cubrid_con) {
|
||||
echo "Database Connection Error";
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
<?php
|
||||
$sql = "select sports, count(players) as players from event group by sports";
|
||||
/**
|
||||
* Request the CUBRID Server for the results of the SQL statement.
|
||||
* Now make the actual connection to the CUBRID Server.
|
||||
*/
|
||||
$result = cubrid_execute($cubrid_con, $sql);
|
||||
|
||||
if ($result) {
|
||||
// Get the column names from the result set created by the SQL query.
|
||||
$columns = cubrid_column_names($result);
|
||||
// Get the number of columns in the result set created by the SQL query.
|
||||
$num_fields = cubrid_num_cols($result);
|
||||
// List the column names of the result set on the screen.
|
||||
echo("<tr>");
|
||||
if ($result) {
|
||||
/**
|
||||
* Get the column names from the result set created by the SQL query.
|
||||
*/
|
||||
$columns = cubrid_column_names($result);
|
||||
/**
|
||||
* Get the number of columns in the result set created by the SQL query.
|
||||
*/
|
||||
$num_fields = cubrid_num_cols($result);
|
||||
/**
|
||||
* List the column names of the result set on the screen.
|
||||
*/
|
||||
echo("<tr>");
|
||||
|
||||
while (list($key, $colname) = each($columns)) {
|
||||
echo("<td align=center>$colname</td>");
|
||||
}
|
||||
while (list($key, $colname) = each($columns)) {
|
||||
echo("<td align=center>$colname</td>");
|
||||
}
|
||||
|
||||
echo("</tr>");
|
||||
echo("</tr>");
|
||||
|
||||
// Get the results from the result set.
|
||||
while ($row = cubrid_fetch($result)) {
|
||||
echo("<tr>");
|
||||
/**
|
||||
* Get the results from the result set.
|
||||
*/
|
||||
while ($row = cubrid_fetch($result)) {
|
||||
echo("<tr>");
|
||||
|
||||
for ($i = 0; $i < $num_fields; $i++) {
|
||||
echo("<td align=center>");
|
||||
echo($row[$i]);
|
||||
echo("</td>");
|
||||
}
|
||||
for ($i = 0; $i < $num_fields; $i++) {
|
||||
echo("<td align=center>");
|
||||
echo($row[$i]);
|
||||
echo("</td>");
|
||||
}
|
||||
|
||||
echo("</tr>");
|
||||
}
|
||||
}
|
||||
// The PHP module in the CUBRID runs in a 3-tier architecture. Even when
|
||||
// calling SELECT for transaction processing, it is processed as a part
|
||||
// of the transaction. Therefore, the transaction needs to be rolled back
|
||||
// by calling commit or rollback even though SELECT was called for smooth
|
||||
// performance.
|
||||
cubrid_commit($cubrid_con);
|
||||
cubrid_disconnect($cubrid_con);
|
||||
?>
|
||||
</body>
|
||||
</html>
|
||||
]]>
|
||||
echo("</tr>");
|
||||
}
|
||||
}
|
||||
/**
|
||||
* The PHP module in the CUBRID runs in a 3-tier architecture. Even when
|
||||
* calling SELECT for transaction processing, it is processed as a part
|
||||
* of the transaction. Therefore, the transaction needs to be rolled back
|
||||
* by calling commit or rollback even though SELECT was called for smooth
|
||||
* performance.
|
||||
*/
|
||||
cubrid_commit($cubrid_con);
|
||||
cubrid_disconnect($cubrid_con);
|
||||
?>
|
||||
</body>
|
||||
</html>
|
||||
]]>
|
||||
</programlisting>
|
||||
</example>
|
||||
<example>
|
||||
<title>Example of Data Insertion</title>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv='content-type' content='text/html; charset=euc- kr'>
|
||||
</head>
|
||||
<body>
|
||||
<center>
|
||||
<table border=2>
|
||||
<?
|
||||
$host_ip = "localhost";
|
||||
$host_port = 33000;
|
||||
$db_name = "demodb";
|
||||
$cubrid_con = @cubrid_connect($host_ip, $host_port, $db_name);
|
||||
<![CDATA[
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=euc- kr">
|
||||
</head>
|
||||
<body>
|
||||
<center>
|
||||
<table border=2>
|
||||
<?php
|
||||
/**
|
||||
* host_ip is the IP address where the CUBRID Broker is installed
|
||||
* host_port is the port number of the CUBRID Broker
|
||||
* db_name is the name of CUBRID Database
|
||||
*/
|
||||
$host_ip = "localhost";
|
||||
$host_port = 33000;
|
||||
$db_name = "demodb";
|
||||
$cubrid_con = @cubrid_connect($host_ip, $host_port, $db_name);
|
||||
|
||||
if (!$cubrid_con) {
|
||||
echo "Database Connection Error";
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
<?
|
||||
$sql = "insert into olympic (host_year,host_nation,host_city,"
|
||||
. "opening_date,closing_date) values (2008, 'China', 'Beijing',"
|
||||
. "to_date('08-08-2008','mm-dd- yyyy'),to_date('08-24-2008','mm-dd-yyyy')) ;"
|
||||
$result = cubrid_execute($cubrid_con, $sql);
|
||||
if ($result) {
|
||||
// Handled successfully, so commit.
|
||||
cubrid_commit($cubrid_con);
|
||||
echo("Inserted successfully ");
|
||||
} else {
|
||||
// Error occurred, so the error message is output and rollback is called.
|
||||
echo(cubrid_error_msg());
|
||||
cubrid_rollback($cubrid_con);
|
||||
}
|
||||
cubrid_disconnect($cubrid_con);
|
||||
?>
|
||||
</body>
|
||||
</html>
|
||||
]]>
|
||||
if (!$cubrid_con) {
|
||||
echo "Database Connection Error";
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
<?php
|
||||
$sql = "insert into olympic (host_year,host_nation,host_city,"
|
||||
. "opening_date,closing_date) values (2008, 'China', 'Beijing',"
|
||||
. "to_date('08-08-2008','mm-dd- yyyy'),to_date('08-24-2008','mm-dd-yyyy')) ;"
|
||||
$result = cubrid_execute($cubrid_con, $sql);
|
||||
if ($result) {
|
||||
/**
|
||||
* Handled successfully, so commit.
|
||||
*/
|
||||
cubrid_commit($cubrid_con);
|
||||
echo("Inserted successfully ");
|
||||
} else {
|
||||
/**
|
||||
* Error occurred, so the error message is output and rollback is called.
|
||||
*/
|
||||
echo(cubrid_error_msg());
|
||||
cubrid_rollback($cubrid_con);
|
||||
}
|
||||
cubrid_disconnect($cubrid_con);
|
||||
?>
|
||||
</body>
|
||||
</html>
|
||||
]]>
|
||||
</programlisting>
|
||||
</example>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>req_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_affected_rows</function> function is used to get the number of rows affected by the SQL sentence (INSERT, DELETE, UPDATE).
|
||||
The <function>cubrid_affected_rows</function> function is used to get the number of rows affected by the SQL sentence (INSERT, DELETE, UPDATE).
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,10 +33,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Number of rows affected by the SQL sentence, when process is successful.
|
||||
Number of rows affected by the SQL sentence, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
-1, when process is unsuccessful.
|
||||
-1, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<methodparam choice="opt"><type>string</type><parameter>bind_value_type</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_bind</function> function is used to bind values in a <function>cubrid_prepare</function> variable, a various types in PHP and corresponding types in SQL.
|
||||
The <function>cubrid_bind</function> function is used to bind values in a <function>cubrid_prepare</function> variable, a various types in PHP and corresponding types in SQL.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -25,7 +25,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle as a result of <function>cubrid_prepare.</function></para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -50,10 +50,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>req_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_close_prepare</function> function closes the request handle given by the <parameter>req_handle</parameter> argument, and releases the memory region related to the handle.
|
||||
The <function>cubrid_close_prepare</function> function closes the request handle given by the <parameter>req_handle</parameter> argument, and releases the memory region related to the handle.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,10 +33,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>req_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_close_request</function> function closes the request handle given by the <parameter>req_handle</parameter> argument, and releases the memory region related to the handle.
|
||||
The <function>cubrid_close_request</function> function closes the request handle given by the <parameter>req_handle</parameter> argument, and releases the memory region related to the handle.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,10 +33,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<methodparam><type>string</type><parameter>attr_name</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_col_get</function> function is used to get contents of the elements of the collection type (set, multiset, sequence) attribute you requested as an array.
|
||||
The <function>cubrid_col_get</function> function is used to get contents of the elements of the collection type (set, multiset, sequence) attribute you requested as an array.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -44,10 +44,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Array (0-based numerical array) containing the elements you requested, when process is successful;
|
||||
Array (0-based numerical array) containing the elements you requested, when process is successful;
|
||||
</para>
|
||||
<para>
|
||||
&false; (to distinguish the error from the situation of attribute having empty collection or NULL, in case of error, a warning message is shown; in such case you can check the error by using <function>cubrid_error_code</function>), when process is unsuccessful.
|
||||
&false; (to distinguish the error from the situation of attribute having empty collection or NULL, in case of error, a warning message is shown; in such case you can check the error by using <function>cubrid_error_code</function>), when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -11,12 +11,12 @@
|
|||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<type>int</type><methodname>cubrid_col_size</methodname>
|
||||
<methodparam><type>int</type><parameter>conn_handle</parameter></methodparam>
|
||||
<methodparam><type>string</type><parameter>oid</parameter></methodparam>
|
||||
<methodparam><type>string</type><parameter>attr_name</parameter></methodparam>
|
||||
<methodparam><type>int</type><parameter>conn_handle</parameter></methodparam>
|
||||
<methodparam><type>string</type><parameter>oid</parameter></methodparam>
|
||||
<methodparam><type>string</type><parameter>attr_name</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_col_size</function> function is used to get the number of elements in a collection type (set, multiset, sequence) attribute.
|
||||
The <function>cubrid_col_size</function> function is used to get the number of elements in a collection type (set, multiset, sequence) attribute.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -43,10 +43,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Number of elements, when process is successful.
|
||||
Number of elements, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
-1, when process is unsuccessful.
|
||||
-1, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>req_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_column_names</function> function is used to get the column names of the query result by using <parameter>req_handle</parameter>.
|
||||
The <function>cubrid_column_names</function> function is used to get the column names of the query result by using <parameter>req_handle</parameter>.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,10 +33,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
array containing column names, when process is successful.
|
||||
array containing column names, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>req_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_column_types</function> function gets column types of query results by using <parameter>req_handle</parameter>.
|
||||
The <function>cubrid_column_types</function> function gets column types of query results by using <parameter>req_handle</parameter>.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,10 +33,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Array containing column types, when process is successful.
|
||||
Array containing column types, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
<type>int</type><methodname>cubrid_commit</methodname>
|
||||
<methodparam><type>int</type><parameter>conn_handle</parameter></methodparam> </methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_commit</function> function is used to execute commit on the transaction pointed by <parameter>conn_handle</parameter>, currently on progress. Connection to the server is closed after the <function>cubrid_commit</function> function is called; the connection handle is still valid, however.
|
||||
The <function>cubrid_commit</function> function is used to execute commit on the transaction pointed by <parameter>conn_handle</parameter>, currently on progress. Connection to the server is closed after the <function>cubrid_commit</function> function is called; the connection handle is still valid, however.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -21,7 +21,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -32,10 +32,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@
|
|||
<methodparam choice="opt"><type>string</type><parameter>passwd</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_connect</function> function is used to establish the environment for connecting to your server by using your server address, port number, database name, user name, and password. If the user name and password is not given, then the "PUBLIC" connection will be made by default.
|
||||
The <function>cubrid_connect</function> function is used to establish the environment for connecting to your server by using your server address, port number, database name, user name, and password. If the user name and password is not given, then the "PUBLIC" connection will be made by default.
|
||||
</para>
|
||||
<para>
|
||||
Calling the <function>cubrid_connect</function> function does not necessarily make the connection to your server. The actual connection will be made when an operation is requested by using the connection handle.
|
||||
Calling the <function>cubrid_connect</function> function does not necessarily make the connection to your server. The actual connection will be made when an operation is requested by using the connection handle.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -29,7 +29,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>host</parameter></term>
|
||||
<listitem><para>Host name of CAS server.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -56,10 +56,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Connection handle, when process is successful.
|
||||
Connection handle, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>req_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_current_oid</function> function is used to get the oid of the current cursor location from the query result. To use <function>cubrid_current_oid</function>, the query executed must be a updatable query, and the CUBRID_ INCLUDE_OID option must be included during the query execution.
|
||||
The <function>cubrid_current_oid</function> function is used to get the oid of the current cursor location from the query result. To use <function>cubrid_current_oid</function>, the query executed must be a updatable query, and the CUBRID_ INCLUDE_OID option must be included during the query execution.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,10 +33,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Oid of current cursor location, when process is successful
|
||||
Oid of current cursor location, when process is successful
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>conn_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_disconnect</function> function ends the transaction currently on process, closes the connection handle and disconnects from server. If there exists any request handle not closed yet at this point, it will be closed.
|
||||
The <function>cubrid_disconnect</function> function ends the transaction currently on process, closes the connection handle and disconnects from server. If there exists any request handle not closed yet at this point, it will be closed.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,10 +33,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<methodparam><type>string</type><parameter>oid</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_drop</function> function is used to delete an instance from database by using <parameter>oid</parameter>.
|
||||
The <function>cubrid_drop</function> function is used to delete an instance from database by using <parameter>oid</parameter>.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -38,10 +38,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<void />
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_error_code_facility</function> function is used to get the facility code (level in which the error occurred) from the error code of the error that occurred during the API execution. Usually, you can get the error code when API returns false as its return value.
|
||||
The <function>cubrid_error_code_facility</function> function is used to get the facility code (level in which the error occurred) from the error code of the error that occurred during the API execution. Usually, you can get the error code when API returns false as its return value.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -26,8 +26,8 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Facility code of the error code that occurred: CUBRID_FACILITY_DBMS, CUBRID_FACILITY_CAS, CUBRID_FACILITY_CCI, CUBRID_FACILITY_CLIENT
|
||||
</para>
|
||||
Facility code of the error code that occurred: CUBRID_FACILITY_DBMS, CUBRID_FACILITY_CAS, CUBRID_FACILITY_CCI, CUBRID_FACILITY_CLIENT
|
||||
</para>
|
||||
<para />
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<void />
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_error_code</function> function is used to get the error code of the error that occurred during the API execution. Usually, it gets the error code when API returns false as its return value.
|
||||
The <function>cubrid_error_code</function> function is used to get the error code of the error that occurred during the API execution. Usually, it gets the error code when API returns false as its return value.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Error code of the error that occurred.
|
||||
Error code of the error that occurred.
|
||||
</para>
|
||||
<para />
|
||||
</refsect1>
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<void />
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_error_msg</function> function is used to get the error message that occurred during the use of CUBRID API. Usually, it gets error message when API returns false as its return value.
|
||||
The <function>cubrid_error_msg</function> function is used to get the error message that occurred during the use of CUBRID API. Usually, it gets error message when API returns false as its return value.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Error message that occurred.
|
||||
Error message that occurred.
|
||||
</para>
|
||||
<para />
|
||||
</refsect1>
|
||||
|
|
|
@ -20,48 +20,48 @@
|
|||
<methodparam><type>int</type><parameter>request_handle</parameter></methodparam>
|
||||
<methodparam choice="opt"><type>int</type><parameter>option</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_execute</function> function is used to execute the given SQL sentence. It executes the query by using <parameter>conn_handle</parameter> and SQL, and then returns the request handle created. It is used for simple execution of query, where the parameter binding is not needed. In addition, the <function>cubrid_execute</function> function is used to execute the prepared statement by means of <function>cubrid_prepare</function> and <function>cubrid_bind</function>. At this time, you need to specify arguments of <parameter>request_handle</parameter> and <parameter>option</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
You can use the <parameter>option</parameter> argument to tell whether to receive oid of the row after the execution, and, whether to execute the query in asynchronous mode. You can use it by setting the CUBRID_INCLUDE_OID and CUBRID_ASYNC using bitwise or operator. If the both variables are not explicitly given, they are not selected by default.
|
||||
</para>
|
||||
<para>
|
||||
If the first argument is <parameter>request_handle</parameter> to execute the <function>cubrid_prepare</function> function, you can specify an option, CUBRID_ASYNC only.
|
||||
</para>
|
||||
<para>
|
||||
The <function>cubrid_execute</function> function is used to execute the given SQL sentence. It executes the query by using <parameter>conn_handle</parameter> and SQL, and then returns the request handle created. It is used for simple execution of query, where the parameter binding is not needed. In addition, the <function>cubrid_execute</function> function is used to execute the prepared statement by means of <function>cubrid_prepare</function> and <function>cubrid_bind</function>. At this time, you need to specify arguments of <parameter>request_handle</parameter> and <parameter>option</parameter>.
|
||||
</para>
|
||||
<para>
|
||||
You can use the <parameter>option</parameter> argument to tell whether to receive oid of the row after the execution, and, whether to execute the query in asynchronous mode. You can use it by setting the CUBRID_INCLUDE_OID and CUBRID_ASYNC using bitwise or operator. If the both variables are not explicitly given, they are not selected by default.
|
||||
</para>
|
||||
<para>
|
||||
If the first argument is <parameter>request_handle</parameter> to execute the <function>cubrid_prepare</function> function, you can specify an option, CUBRID_ASYNC only.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="parameters">
|
||||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>SQL</parameter></term>
|
||||
<listitem><para>SQL to be executed.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>option</parameter></term>
|
||||
<listitem><para>Query execution option CUBRID_INCLUDE_OID, CUBRID_ASYNC.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>request_handle</parameter></term>
|
||||
<listitem><para><function>cubrid_prepare</function> handle.</para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>SQL</parameter></term>
|
||||
<listitem><para>SQL to be executed.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>option</parameter></term>
|
||||
<listitem><para>Query execution option CUBRID_INCLUDE_OID, CUBRID_ASYNC.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>request_handle</parameter></term>
|
||||
<listitem><para><function>cubrid_prepare</function> handle.</para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Request handle, when process is successful.
|
||||
Request handle, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<methodparam choice="opt"><type>int</type><parameter>type</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_fetch</function> function is used to get a single row from the query result. The cursor automatically moves to the next row after getting the result.
|
||||
The <function>cubrid_fetch</function> function is used to get a single row from the query result. The cursor automatically moves to the next row after getting the result.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -40,12 +40,12 @@
|
|||
<para>Result array or object, when process is successful.</para>
|
||||
<para>&false;, when process is unsuccessful.</para>
|
||||
<para>The result can be received either as an array or as an object, and you can decide which data type to use by setting the <parameter>type</parameter> argument. The <parameter>type</parameter> variable can be set to one of the following values:</para>
|
||||
<simplelist>
|
||||
<member>CUBRID_NUM : Numerical array (0-based)</member>
|
||||
<member>CUBRID_ASSOC : Associative array</member>
|
||||
<member>CUBRID_BOTH : Numerical & Associative array (default)</member>
|
||||
<member>CUBRID_OBJECT : object that has the attribute name as the column name of query result</member>
|
||||
</simplelist>
|
||||
<simplelist>
|
||||
<member>CUBRID_NUM : Numerical array (0-based)</member>
|
||||
<member>CUBRID_ASSOC : Associative array</member>
|
||||
<member>CUBRID_BOTH : Numerical & Associative array (default)</member>
|
||||
<member>CUBRID_OBJECT : object that has the attribute name as the column name of query result</member>
|
||||
</simplelist>
|
||||
<para>When <parameter>type</parameter> argument is omitted, the result will be received using CUBRID_BOTH option as default. When you want to receive query result in object data type, the column name of the result must obey the naming rules for identifiers in PHP. For example, column name such as "count(*)" cannot be received in object type.</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<methodparam><type>string</type><parameter>oid</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_get_class_name</function> function is used to get the class name from <parameter>oid</parameter>.
|
||||
The <function>cubrid_get_class_name</function> function is used to get the class name from <parameter>oid</parameter>.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -38,10 +38,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Class name when process is successful.
|
||||
Class name when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<methodparam choice="opt"><type>mixed</type><parameter>attr</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_get</function> function is used to get the attribute of the instance of the given <parameter>oid</parameter>. You can get single attribute by using string data type for the <parameter>attr</parameter> argument, or many attributes by using array data type for the <parameter>attr</parameter> argument.
|
||||
The <function>cubrid_get</function> function is used to get the attribute of the instance of the given <parameter>oid</parameter>. You can get single attribute by using string data type for the <parameter>attr</parameter> argument, or many attributes by using array data type for the <parameter>attr</parameter> argument.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<methodparam><type>string</type><parameter>oid</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_is_instance</function> function is used to check whether the instance pointed by the given <parameter>oid</parameter> exists or not.
|
||||
The <function>cubrid_is_instance</function> function is used to check whether the instance pointed by the given <parameter>oid</parameter> exists or not.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -38,13 +38,13 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
1, if such instance exists;
|
||||
1, if such instance exists;
|
||||
</para>
|
||||
<para>
|
||||
0, if such instance does not exist;
|
||||
0, if such instance does not exist;
|
||||
</para>
|
||||
<para>
|
||||
-1, in case of error
|
||||
-1, in case of error
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<methodparam><type>string</type><parameter>file_name</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_load_from_glo</function> function is used to read a data from a glo instance, and saves it in a designated file.
|
||||
The <function>cubrid_load_from_glo</function> function is used to read a data from a glo instance, and saves it in a designated file.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -43,10 +43,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<methodparam><type>string</type><parameter>oid</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_lock_read</function> function is used to put read lock on the instance pointed by given <parameter>oid</parameter>.
|
||||
The <function>cubrid_lock_read</function> function is used to put read lock on the instance pointed by given <parameter>oid</parameter>.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -38,10 +38,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<methodparam><type>string</type><parameter>oid</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_lock_write</function> function is used to put write lock on the instance pointed by the given <parameter>oid</parameter>.
|
||||
The <function>cubrid_lock_write</function> function is used to put write lock on the instance pointed by the given <parameter>oid</parameter>.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -38,10 +38,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -16,10 +16,10 @@
|
|||
<methodparam choice="opt"><type>int</type><parameter>origin</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_move_cursor</function> function is used to move the current cursor location of <parameter>req_handle</parameter> by the value set in the <parameter>offset</parameter> argument, to the direction set in the <parameter>origin</parameter> argument. To set the <parameter>origin</parameter> argument, you can use CUBRID_CURSOR_FIRST for the first part of the result, CUBRID_CURSOR_CURRENT for the current location of the result, or CUBRID_CURSOR_LAST for the last part of the result. If <parameter>origin</parameter> argument is not explicitly designated, then the function uses CUBRID_CURSOR_CURRENT as its default value.
|
||||
The <function>cubrid_move_cursor</function> function is used to move the current cursor location of <parameter>req_handle</parameter> by the value set in the <parameter>offset</parameter> argument, to the direction set in the <parameter>origin</parameter> argument. To set the <parameter>origin</parameter> argument, you can use CUBRID_CURSOR_FIRST for the first part of the result, CUBRID_CURSOR_CURRENT for the current location of the result, or CUBRID_CURSOR_LAST for the last part of the result. If <parameter>origin</parameter> argument is not explicitly designated, then the function uses CUBRID_CURSOR_CURRENT as its default value.
|
||||
</para>
|
||||
<para>
|
||||
If the value of cursor movement range goes over the valid limit, then the cursor moves to the next location after the valid range for the cursor. For example, if you move 20 units in the result with the size of 10, then the cursor will move to 11th place and return CUBRID_NO_MORE_DATA.
|
||||
If the value of cursor movement range goes over the valid limit, then the cursor moves to the next location after the valid range for the cursor. For example, if you move 20 units in the result with the size of 10, then the cursor will move to 11th place and return CUBRID_NO_MORE_DATA.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -46,13 +46,13 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
CUBRID_CURSOR_SUCCESS, when process is successful.
|
||||
CUBRID_CURSOR_SUCCESS, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
CUBRID_NO_MORE_DATA, when it is not a valid cursor location.
|
||||
CUBRID_NO_MORE_DATA, when it is not a valid cursor location.
|
||||
</para>
|
||||
<para>
|
||||
CUBRID_CURSOR_ERROR, in case of error.
|
||||
CUBRID_CURSOR_ERROR, in case of error.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<methodparam><type>string</type><parameter>file_name</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_new_glo</function> function is used to create a glo instance in the requested class (glo class). The glo created is a LO type, and is stored in the <parameter>file_name</parameter> file.
|
||||
The <function>cubrid_new_glo</function> function is used to create a glo instance in the requested class (glo class). The glo created is a LO type, and is stored in the <parameter>file_name</parameter> file.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -43,10 +43,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Oid of the instance created, when process is successful.
|
||||
Oid of the instance created, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -77,8 +77,8 @@ if ($oid){
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_save_to_glo</function></member>
|
||||
<member><function>cubrid_load_from_glo</function></member>
|
||||
<member><function>cubrid_send_glo</function></member>
|
||||
<member><function>cubrid_load_from_glo</function></member>
|
||||
<member><function>cubrid_send_glo</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>req_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_num_cols</function> function is used to get the number of columns from the query result. It can only be used when the query executed is a select sentence.
|
||||
The <function>cubrid_num_cols</function> function is used to get the number of columns from the query result. It can only be used when the query executed is a select sentence.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,10 +33,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Number of columns, when process is successful.
|
||||
Number of columns, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
-1, in case of error.
|
||||
-1, in case of error.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -66,7 +66,7 @@ if ($req) {
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_execute</function></member>
|
||||
<member><function>cubrid_num_rows</function></member>
|
||||
<member><function>cubrid_num_rows</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<methodparam><type>int</type><parameter>req_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_num_rows</function> function is used to get the number of rows from the query result. You can use it only when the query executed is a select sentence. When you want to know such value for INSERT, UPDATE, or DELETE query, you have to use the <function>cubrid_affected_rows</function> function. The <function>cubrid_num_rows</function> function can only be used for synchronous query; it returns 0 when it is used for asynchronous query.
|
||||
The <function>cubrid_num_rows</function> function is used to get the number of rows from the query result. You can use it only when the query executed is a select sentence. When you want to know such value for INSERT, UPDATE, or DELETE query, you have to use the <function>cubrid_affected_rows</function> function. The <function>cubrid_num_rows</function> function can only be used for synchronous query; it returns 0 when it is used for asynchronous query.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>req_handle</parameter></term>
|
||||
<listitem><para>Request handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,13 +33,13 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Number of rows, when process is successful.
|
||||
Number of rows, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
0 when the query was done in async mode.
|
||||
0 when the query was done in async mode.
|
||||
</para>
|
||||
<para>
|
||||
-1, in case of error.
|
||||
-1, in case of error.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -69,8 +69,8 @@ if ($req) {
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_execute</function></member>
|
||||
<member><function>cubrid_num_cols</function></member>
|
||||
<member><function>cubrid_affected_rows</function></member>
|
||||
<member><function>cubrid_num_cols</function></member>
|
||||
<member><function>cubrid_affected_rows</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<methodparam choice="opt"><type>int</type><parameter>option</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_prepare</function> function is a sort of API which represents SQL statements compiled previously to a given connection handle. This pre-compiled SQL statement will be included in the <function>cubrid_prepare</function>. Accccordingly, you can use this statement effectively to execute several times repeatedly or to process long data. Only a single statement can be used and a parameter may put a question mark (?) to appropriate area in the SQL statement. Add a parameter when you bind a value in the VALUES cluse of INSERT statement or in the WHERE clause. Note that it is allowed to bind a value to a MARK(?) by the <function>cubrid_bind</function> only.
|
||||
The <function>cubrid_prepare</function> function is a sort of API which represents SQL statements compiled previously to a given connection handle. This pre-compiled SQL statement will be included in the <function>cubrid_prepare</function>. Accccordingly, you can use this statement effectively to execute several times repeatedly or to process long data. Only a single statement can be used and a parameter may put a question mark (?) to appropriate area in the SQL statement. Add a parameter when you bind a value in the VALUES cluse of INSERT statement or in the WHERE clause. Note that it is allowed to bind a value to a MARK(?) by the <function>cubrid_bind</function> only.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -43,10 +43,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Request handle, if process is successful;
|
||||
Request handle, if process is successful;
|
||||
</para>
|
||||
<para>
|
||||
&false;, if process is unsuccessful.
|
||||
&false;, if process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -79,7 +79,7 @@ $sql = "insert into tbl values ( ?,?,?)";
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_execute</function></member>
|
||||
<member><function>cubrid_bind</function></member>
|
||||
<member><function>cubrid_bind</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<methodparam><type>mixed</type><parameter>value</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_put</function> function is used to update an attribute of the instance of the given <parameter>oid</parameter>. You can update single attribute by using string data type to set <parameter>attr</parameter>. In such case, you can use integer, float-point, or string type data for the <parameter>value</parameter> argument. To update multiple number of attributes, you can disregard the <parameter>attr</parameter> argument, and set <parameter>value</parameter> argument with associative array data type. However, you cannot use the method for attribute of collection type. You have to use APIs related to collection type (<function>cubrid_set_add</function>, <function>cubrid_set_drop</function>, etc) when you want to use <function>cubrid_put</function> on collection typed attribute.
|
||||
The <function>cubrid_put</function> function is used to update an attribute of the instance of the given <parameter>oid</parameter>. You can update single attribute by using string data type to set <parameter>attr</parameter>. In such case, you can use integer, float-point, or string type data for the <parameter>value</parameter> argument. To update multiple number of attributes, you can disregard the <parameter>attr</parameter> argument, and set <parameter>value</parameter> argument with associative array data type. However, you cannot use the method for attribute of collection type. You have to use APIs related to collection type (<function>cubrid_set_add</function>, <function>cubrid_set_drop</function>, etc) when you want to use <function>cubrid_put</function> on collection typed attribute.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -25,7 +25,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -48,10 +48,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -78,11 +78,11 @@ cubrid_put ($con, $oid, "hobbies", array("aa", "bb"));
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_get</function></member>
|
||||
<member><function>cubrid_set_add</function></member>
|
||||
<member><function>cubrid_set_drop</function></member>
|
||||
<member><function>cubrid_seq_insert</function></member>
|
||||
<member><function>cubrid_seq_drop</function></member>
|
||||
<member><function>cubrid_seq_put</function></member>
|
||||
<member><function>cubrid_set_add</function></member>
|
||||
<member><function>cubrid_set_drop</function></member>
|
||||
<member><function>cubrid_seq_insert</function></member>
|
||||
<member><function>cubrid_seq_drop</function></member>
|
||||
<member><function>cubrid_seq_put</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -11,13 +11,13 @@
|
|||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<type>int</type><methodname>cubrid_rollback</methodname>
|
||||
<methodparam><type>int</type><parameter>conn_handle</parameter></methodparam>
|
||||
<methodparam><type>int</type><parameter>conn_handle</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_rollback</function> function executes rollback on the transaction pointed by <parameter>conn_handle</parameter>, currently in progress.
|
||||
The <function>cubrid_rollback</function> function executes rollback on the transaction pointed by <parameter>conn_handle</parameter>, currently in progress.
|
||||
</para>
|
||||
<para>
|
||||
Connection to server is closed after calling <function>cubrid_rollback</function>. Connection handle, however, is still valid.
|
||||
Connection to server is closed after calling <function>cubrid_rollback</function>. Connection handle, however, is still valid.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -25,7 +25,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -36,10 +36,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -70,7 +70,7 @@ if ($req) {
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_commit</function></member>
|
||||
<member><function>cubrid_disconnect</function></member>
|
||||
<member><function>cubrid_disconnect</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<methodparam><type>string</type><parameter>file_name</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_save_to_glo</function> function is used to save requested file in a glo instance.
|
||||
The <function>cubrid_save_to_glo</function> function is used to save requested file in a glo instance.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -43,10 +43,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -77,8 +77,8 @@ if ($req) {
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_new_glo</function></member>
|
||||
<member><function>cubrid_load_from_glo</function></member>
|
||||
<member><function>cubrid_send_glo</function></member>
|
||||
<member><function>cubrid_load_from_glo</function></member>
|
||||
<member><function>cubrid_send_glo</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<methodparam choice="opt"><type>string</type><parameter>attr_name</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_schema</function> function is used to get the requested schema information from database. You have to designate <parameter>class_name</parameter>, if you want to get information on certain class, <parameter>attr_name</parameter>, if you want to get information on certain attribute (can be used only with CUBRID_ SCH_ATTR_PRIVILEGE).
|
||||
The <function>cubrid_schema</function> function is used to get the requested schema information from database. You have to designate <parameter>class_name</parameter>, if you want to get information on certain class, <parameter>attr_name</parameter>, if you want to get information on certain attribute (can be used only with CUBRID_ SCH_ATTR_PRIVILEGE).
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -25,7 +25,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -48,10 +48,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
array containing the schema information, when process is successful;
|
||||
array containing the schema information, when process is successful;
|
||||
</para>
|
||||
<para>
|
||||
-1, when process is unsuccessful
|
||||
-1, when process is unsuccessful
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
<methodparam><type>string</type><parameter>oid</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_send_glo</function> function is used to read data from glo instance and sends it to the PHP standard output.
|
||||
The <function>cubrid_send_glo</function> function is used to read data from glo instance and sends it to the PHP standard output.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -38,10 +38,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -70,8 +70,8 @@ if ($req) {
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_new_glo</function></member>
|
||||
<member><function>cubrid_save_to_glo</function></member>
|
||||
<member><function>cubrid_load_from_glo</function></member>
|
||||
<member><function>cubrid_save_to_glo</function></member>
|
||||
<member><function>cubrid_load_from_glo</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<methodparam><type>int</type><parameter>index</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_seq_drop</function> function is used to delete an element you request from the given sequence type attribute in the database.
|
||||
The <function>cubrid_seq_drop</function> function is used to delete an element you request from the given sequence type attribute in the database.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -25,7 +25,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,7 +33,7 @@
|
|||
<term><parameter>oid</parameter></term>
|
||||
<listitem><para>Oid of the instance you want to work with.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>attr_name</parameter></term>
|
||||
<listitem><para>Name of the attribute that you want to delete an element from.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -48,10 +48,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -82,7 +82,7 @@ if ($val == "1") {
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_seq_insert</function></member>
|
||||
<member><function>cubrid_seq_put</function></member>
|
||||
<member><function>cubrid_seq_put</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
<methodparam><type>string</type><parameter>seq_element</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_col_insert</function> function is used to insert an element to a sequence type attribute in a requested location.
|
||||
The <function>cubrid_col_insert</function> function is used to insert an element to a sequence type attribute in a requested location.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -34,7 +34,7 @@
|
|||
<term><parameter>oid</parameter></term>
|
||||
<listitem><para>Oid of the instance you want to work with.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>attr_name</parameter></term>
|
||||
<listitem><para>Name of the attribute you want to insert an instance to.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -53,10 +53,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -80,7 +80,7 @@ cubrid_seq_insert ($con, $oid, "tel", 1, "02-3430-1300");
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_seq_drop</function></member>
|
||||
<member><function>cubrid_seq_put</function></member>
|
||||
<member><function>cubrid_seq_put</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
<methodparam><type>string</type><parameter>seq_element</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_seq_put</function> function is used to update the content of the requested element in a sequent type attribute.
|
||||
The <function>cubrid_seq_put</function> function is used to update the content of the requested element in a sequent type attribute.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -34,7 +34,7 @@
|
|||
<term><parameter>oid</parameter></term>
|
||||
<listitem><para>Oid of the instance you want to work with.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>attr_name</parameter></term>
|
||||
<listitem><para>Name of the attribute that you want to update an element.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -53,10 +53,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -80,7 +80,7 @@ cubrid_seq_put ($con, $oid, "tel", 2, "02-3430-1300");
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_seq_drop</function></member>
|
||||
<member><function>cubrid_seq_insert</function></member>
|
||||
<member><function>cubrid_seq_insert</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<methodparam><type>string</type><parameter>set_element</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_set_add</function> function is used to insert a single element to a set type attribute (set, multiset) you requested.
|
||||
The <function>cubrid_set_add</function> function is used to insert a single element to a set type attribute (set, multiset) you requested.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -25,7 +25,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,7 +33,7 @@
|
|||
<term><parameter>oid</parameter></term>
|
||||
<listitem><para>Oid of the instance you want to work with.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>attr_name</parameter></term>
|
||||
<listitem><para>Name of the attribute you want to insert an element.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -48,10 +48,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<methodparam><type>string</type><parameter>set_element</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_set_drop</function> function is used to delete an element that you request from the given set type (set, multiset) attribute of the database.
|
||||
The <function>cubrid_set_drop</function> function is used to delete an element that you request from the given set type (set, multiset) attribute of the database.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -25,7 +25,7 @@
|
|||
&reftitle.parameters;
|
||||
<para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>conn_handle</parameter></term>
|
||||
<listitem><para>Connection handle.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -33,7 +33,7 @@
|
|||
<term><parameter>oid</parameter></term>
|
||||
<listitem><para>Oid of the instance you want to work with.</para></listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
<varlistentry>
|
||||
<term><parameter>attr_name</parameter></term>
|
||||
<listitem><para>Name of the attribute you want to delete an element from.</para></listitem>
|
||||
</varlistentry>
|
||||
|
@ -48,10 +48,10 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
&true;, when process is successful.
|
||||
&true;, when process is successful.
|
||||
</para>
|
||||
<para>
|
||||
&false;, when process is unsuccessful.
|
||||
&false;, when process is unsuccessful.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<void />
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
The <function>cubrid_version</function> function is used to get the CUBRID PHP module’s version.
|
||||
The <function>cubrid_version</function> function is used to get the CUBRID PHP module’s version.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Version information (eg. "1.2.0").
|
||||
Version information (eg. "1.2.0").
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -49,7 +49,7 @@ echo cubrid_version();
|
|||
<para>
|
||||
<simplelist>
|
||||
<member><function>cubrid_error_code</function></member>
|
||||
<member><function>cubrid_error_code_facility</function></member>
|
||||
<member><function>cubrid_error_code_facility</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
|
|
@ -4,63 +4,14 @@
|
|||
<chapter xml:id="cubrid.setup" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
&reftitle.setup;
|
||||
|
||||
<section xml:id="cubrid.requirements">
|
||||
&reftitle.required;
|
||||
<para>
|
||||
In order to have these functions available, you must install PHP API for CUBRID (<link xlink:href="&url.cubrid.php.api;">CUBRID PHP API</link>).
|
||||
<section xml:id="cubrid.requirements" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
&reftitle.required;
|
||||
<para>
|
||||
In order to have these functions available, you must install PHP API for CUBRID (<link xlink:href="&url.cubrid.php.api;">CUBRID PHP API</link>).
|
||||
</para>
|
||||
</section>
|
||||
|
||||
<section xml:id="cubrid.installation">
|
||||
&reftitle.install;
|
||||
<para>
|
||||
From the CUBRID homepage (<link xlink:href="&url.cubrid;">CUBRID</link>), download the PHP module.
|
||||
</para>
|
||||
<section>
|
||||
<title>Installing PHP for Windows</title>
|
||||
<para>
|
||||
Create a directory named CUBRID in the directory where PHP is installed, and then copy the <parameter>cubrid_err.msg</parameter> file and the .dll file of the cubrid_php version you just downloaded. If you download CUBRID PHP version 5.1.4, add required settings as shown in the example below by editing the php.ini file.
|
||||
</para>
|
||||
<programlisting>
|
||||
<![CDATA[
|
||||
extension_dir=C:\PHP\CUBRID
|
||||
extension=cubrid_php5.1.4.dll
|
||||
[CUBRID]
|
||||
cubrid.err_path=C:\PHP\CUBRID
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
Once the configuration is complete, restart the web server. If you can see the CUBRID information as shown below when you check the PHP configuration using the phpinfo() function of PHP, it means that the installation was successful.
|
||||
</para>
|
||||
</section>
|
||||
<section>
|
||||
<title>Installing PHP for Linux</title>
|
||||
<para>
|
||||
Unlike Windows, Linux provides its source code. Download the source code from the CUBRID homepage (<link xlink:href="&url.cubrid;">CUBRID</link>), and install it by following the INSTALL file of the compressed file. Also in the Linux version, edit and save the php.ini file, and then restart the web server.
|
||||
</para>
|
||||
<programlisting>
|
||||
<![CDATA[
|
||||
; Directory in which the loadable extensions (modules) reside.
|
||||
extension_dir = /usr/lib/php5/lib/php/ext
|
||||
extension=cubrid.so
|
||||
;for Windows, extension=cubrid.dll
|
||||
[CUBRID]
|
||||
cubrid.err_path=/home/cubrid/CUBRID/msg
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
Check the configuration using phpinfo() function.
|
||||
</para>
|
||||
<programlisting>
|
||||
<![CDATA[
|
||||
[root@localhost]#vi test.php
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
As with the Windows version of PHP, if you can see the CUBRID information on the web browser, it means that the installation was successful.
|
||||
</para>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
&reference.cubrid.configure;
|
||||
|
||||
<section xml:id="cubrid.configuration">
|
||||
&reftitle.runtime;
|
||||
|
@ -70,7 +21,7 @@
|
|||
<section xml:id="cubrid.resources">
|
||||
&reftitle.resources;
|
||||
<para>
|
||||
There are two resource types used in the CUBRID. The first one is the link identifier for a database connection, the second a resource which holds the result of a query.
|
||||
There are two resource types used in the CUBRID. The first one is the link identifier for a database connection, the second a resource which holds the result of a query.
|
||||
</para>
|
||||
</section>
|
||||
|
||||
|
|
Loading…
Reference in a new issue