cvs: phpdoc /en/reference/maxdb book.xml constants.xml examples.xml reference.xml setup.xml

From: Date: Wed, 26 Dec 2007 13:10:50 +0000
Subject: cvs: phpdoc /en/reference/maxdb book.xml constants.xml examples.xml reference.xml setup.xml
Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-819@lists.php.net to get a copy of this message
bjori Wed Dec 26 13:10:50 2007 UTC Modified files: /phpdoc/en/reference/maxdb book.xml examples.xml setup.xml constants.xml reference.xml Log: MFB: Upgrade to the new-reference-structure - (Created missing setup sections in setup.xml, if any) - Moved the intro to book.xml - Changed the intro ID from <extname>.intro to intro.<extname> - Moved the constants entity to book.xml - Changed constants.xml to be an appendix - Moved the examples to its own chapter (examples.xml) NOTE: The orginal maxdb.examples section ID was renamed to maxdb.examples-basic The chapter itself is maxdb.examples - Moved the configure and ini entities to setup.xml - Moved the requirements and resources sections to setup.xml

http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/maxdb/book.xml?r1=1.1&r2=1.2&diff_format=u Index: phpdoc/en/reference/maxdb/book.xml diff -u /dev/null phpdoc/en/reference/maxdb/book.xml:1.2 --- /dev/null Wed Dec 26 13:10:50 2007 +++ phpdoc/en/reference/maxdb/book.xml Wed Dec 26 13:10:49 2007 @@ -0,0 +1,75 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- $Revision: 1.2 $ --> +<!-- Purpose: database.vendors --> +<!-- Membership: pecl, external --> + +<book xml:id="book.maxdb" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> + <title>MaxDB</title> + + <!-- {{{ preface --> + <preface xml:id="intro.maxdb"> + &reftitle.intro; + <para> + The MaxDB PHP extension allows you to access the functionality provided by + MaxDB 7.5.0 and above. More information about the MaxDB Database server + can be found at <link xlink:href="&url.maxdb;">&url.maxdb;</link>. + </para> + <para> + The MaxDB PHP extension is compatible to the MySQL mysqli extension. There are only + minor differences in the behaviour of some functions due to the differences of the + underlying database servers, MaxDB and MySQL. + </para> + <para> + The main differences to mysqli are in the following functions: + </para> + <simplelist> + <member><function>maxdb_character_set_name</function> - Returns only ascii or unicode.</member> + <member><function>maxdb_get_client_info</function> - Returns a different version string.</member> + <member><function>maxdb_get_client_version</function> - Returns a different version string.</member> + <member><function>maxdb_get_host_info</function> - Returns localhost or hostname.</member> + <member><function>maxdb_get_server_info</function> - Returns a different version string.</member> + <member><function>maxdb_get_server_version</function> - Returns a different version string.</member> + <member><function>maxdb_kill</function> - Only disconnects the session.</member> + <member><function>maxdb_multi_query</function> - Can not handle multiple SQL statements.</member> + <member><function>maxdb_next_result</function> - Function returns always false.</member> + <member><function>maxdb_options</function> - Supports a different set of options.</member> + <member><function>maxdb_report</function> - Supports a different report mode.</member> + <member><function>maxdb_stat</function> - Returns a different system status string.</member> + <member><function>maxdb_stmt_store_result</function> - Is not necessary for MaxDB.</member> + <member><function>maxdb_store_result</function> - Is not necessary for MaxDB.</member> + </simplelist> + <para> + Documentation for MaxDB can be found at + <link xlink:href="&url.maxdb.doc;">&url.maxdb.doc;</link>. + </para> + </preface> + <!-- }}} --> + + &reference.maxdb.setup; + &reference.maxdb.constants; + &reference.maxdb.examples; + &reference.maxdb.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 +--> + http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/maxdb/examples.xml?r1=1.1&r2=1.2&diff_format=u Index: phpdoc/en/reference/maxdb/examples.xml diff -u /dev/null phpdoc/en/reference/maxdb/examples.xml:1.2 --- /dev/null Wed Dec 26 13:10:50 2007 +++ phpdoc/en/reference/maxdb/examples.xml Wed Dec 26 13:10:49 2007 @@ -0,0 +1,155 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- $Revision: 1.2 $ --> + +<chapter xml:id="maxdb.examples" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> + &reftitle.examples; + <section xml:id="maxdb.examples-basic"> + <para> + All examples in the MaxDB PHP documentation use the HOTELDB demo database from MaxDB. More about this + database can be found at <link xlink:href="&url.maxdb.sampledb;">&url.maxdb.sampledb;</link>. + </para> + <para> + To use the examples in the MaxDB PHP documentation, you have to load the tutorial data into your database. + Then you have to set maxdb.default_db in &php.ini; to the database that contains the tutorial data. + </para> + <para> + This simple example shows how to connect, execute a query, print + resulting rows and disconnect from a MaxDB database. + <example> + <title>MaxDB extension overview example</title> + <programlisting role="php"> +<![CDATA[ +<?php +$link = maxdb_connect("localhost", "MONA", "RED", "DEMODB"); + +/* check connection */ +if (maxdb_connect_errno()) { + printf("Connect failed: %s\n", maxdb_connect_error()); + exit(); +} + +/* Performing SQL query */ +$query = "SELECT * FROM hotel.city"; +$result = maxdb_query($link, $query) or die("Query failed : " . maxdb_error()); + +/* Printing results in HTML */ +echo "<table>\n"; +while ($line = maxdb_fetch_array($result, MAXDB_ASSOC)) { + echo " <tr>\n"; + foreach ($line as $col_value) { + echo " <td>$col_value</td>\n"; + } + echo " </tr>\n"; +} +echo "</table>\n"; + +/* Free resultset */ +maxdb_free_result($result); + +/* Closing connection */ +maxdb_close($link); +?> +]]> + </programlisting> + </example> + </para> + <para> + The following example shows how to bind variables to a SELECT INTO statement. + <example> + <title>Example for use of SELECT INTO statements</title> + <programlisting role="php"> +<![CDATA[ +<?php +$link = maxdb_connect("localhost", "MONA", "RED", "DEMODB"); + +/* check connection */ +if (!$link) { + printf("Connect failed: %s\n", maxdb_connect_error()); + exit(); +} + +/* Performing SQL query */ +$stmt = maxdb_prepare ($link, "SELECT percentage INTO ? FROM hotel.countrylanguage where language = ?"); +if (!$stmt) { + printf ("Prepare failed: %s\n", maxdb_error($link)); +} + +$name = "Mbundu"; + +maxdb_stmt_bind_param($stmt, 'ds', $percentage, $name); +maxdb_stmt_execute($stmt); + +printf ("%f\n", $percentage); + +maxdb_stmt_close ($stmt); +?> +]]> + </programlisting> + </example> + </para> + <para> + The following example shows how to use MaxDB database procedures. + <example> + <title>Example fore using database procedures</title> + <programlisting role="php"> +<![CDATA[ +<?php +$link = maxdb_connect("localhost", "MONA", "RED", "DEMODB"); + +/* check connection */ +if (!$link) { + printf("Connect failed: %s\n", maxdb_connect_error()); + exit(); +} + +maxdb_report (MAXDB_REPORT_OFF); +maxdb_query($link,"DROP DBPROC test_proc"); +maxdb_report (MAXDB_REPORT_ERROR); + +$query = "create dbproc test_proc (INOUT e_text char(72)) AS select * from SYSDBA.DUAL; fetch into :e_text;"; + +maxdb_query($link, $query); + +/* Performing SQL query */ +$stmt = maxdb_prepare ($link, "CALL test_proc (?)"); +if (!$stmt) { + printf ("Prepare failed: %s\n", maxdb_error($link)); +} + +maxdb_stmt_bind_param($stmt, 's', $result); +maxdb_stmt_execute($stmt); + +printf ("%s\n", $result); + +maxdb_stmt_close ($stmt); +?> +]]> + </programlisting> + </example> + </para> + </section> + +</chapter> + +<!-- 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 +--> + + http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/maxdb/setup.xml?r1=1.1&r2=1.2&diff_format=u Index: phpdoc/en/reference/maxdb/setup.xml diff -u /dev/null phpdoc/en/reference/maxdb/setup.xml:1.2 --- /dev/null Wed Dec 26 13:10:50 2007 +++ phpdoc/en/reference/maxdb/setup.xml Wed Dec 26 13:10:50 2007 @@ -0,0 +1,65 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- $Revision: 1.2 $ --> + +<chapter xml:id="maxdb.setup" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> + &reftitle.setup; + + <!-- {{{ Requirements --> + <section xml:id="maxdb.requirements"> + &reftitle.required; + <para> + In order to have these functions available, you must compile PHP with + MaxDB support. Additionally, you must have the MaxDB SQLDBC runtime library + available to access the MaxDB server. + </para> + <para> + Documentation for MaxDB SQLDBC can be found at + <link xlink:href="&url.maxdb.doc;">&url.maxdb.doc;</link>. + </para> + <para> + Download the MaxDB SQLDBC package from + <link xlink:href="&url.maxdb.sdbc;">&url.maxdb.sdbc;</link>. + </para> + </section> + <!-- }}} --> + + <!-- {{{ Installation --> + &reference.maxdb.configure; + <!-- }}} --> + + <!-- {{{ Configuration --> + &reference.maxdb.ini; + <!-- }}} --> + + <!-- {{{ Resources --> + <section xml:id="maxdb.resources"> + &reftitle.resources; + <para> + This extension defines resources. + </para> + </section> + <!-- }}} --> + +</chapter> + +<!-- 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 +--> + http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/maxdb/constants.xml?r1=1.4&r2=1.5&diff_format=u Index: phpdoc/en/reference/maxdb/constants.xml diff -u phpdoc/en/reference/maxdb/constants.xml:1.4 phpdoc/en/reference/maxdb/constants.xml:1.5 --- phpdoc/en/reference/maxdb/constants.xml:1.4 Wed Jun 20 22:24:51 2007 +++ phpdoc/en/reference/maxdb/constants.xml Wed Dec 26 13:10:49 2007 @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.4 $ --> -<section xml:id="maxdb.constants" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> +<!-- $Revision: 1.5 $ --> +<appendix xml:id="maxdb.constants" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> &reftitle.constants; &extension.constants; <para> @@ -127,7 +127,7 @@ </tgroup> </table> </para> -</section> +</appendix> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/maxdb/reference.xml?r1=1.13&r2=1.14&diff_format=u Index: phpdoc/en/reference/maxdb/reference.xml diff -u phpdoc/en/reference/maxdb/reference.xml:1.13 phpdoc/en/reference/maxdb/reference.xml:1.14 --- phpdoc/en/reference/maxdb/reference.xml:1.13 Mon Dec 10 17:06:05 2007 +++ phpdoc/en/reference/maxdb/reference.xml Wed Dec 26 13:10:50 2007 @@ -1,72 +1,13 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.13 $ --> -<!-- Purpose: database.vendors --> -<!-- Membership: pecl, external --> +<!-- $Revision: 1.14 $ --> <reference xml:id="ref.maxdb" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> - <title>MaxDB PHP Extension</title> - <titleabbrev>MaxDB</titleabbrev> + <title>MaxDB PHP &Functions;</title> <partintro> - <section xml:id="maxdb.intro"> - &reftitle.intro; - <para> - The MaxDB PHP extension allows you to access the functionality provided by - MaxDB 7.5.0 and above. More information about the MaxDB Database server - can be found at <link xlink:href="&url.maxdb;">&url.maxdb;</link>. - </para> - <para> - The MaxDB PHP extension is compatible to the MySQL mysqli extension. There are only - minor differences in the behaviour of some functions due to the differences of the - underlying database servers, MaxDB and MySQL. - </para> - <para> - The main differences to mysqli are in the following functions: - </para> - <simplelist> - <member><function>maxdb_character_set_name</function> - Returns only ascii or unicode.</member> - <member><function>maxdb_get_client_info</function> - Returns a different version string.</member> - <member><function>maxdb_get_client_version</function> - Returns a different version string.</member> - <member><function>maxdb_get_host_info</function> - Returns localhost or hostname.</member> - <member><function>maxdb_get_server_info</function> - Returns a different version string.</member> - <member><function>maxdb_get_server_version</function> - Returns a different version string.</member> - <member><function>maxdb_kill</function> - Only disconnects the session.</member> - <member><function>maxdb_multi_query</function> - Can not handle multiple SQL statements.</member> - <member><function>maxdb_next_result</function> - Function returns always false.</member> - <member><function>maxdb_options</function> - Supports a different set of options.</member> - <member><function>maxdb_report</function> - Supports a different report mode.</member> - <member><function>maxdb_stat</function> - Returns a different system status string.</member> - <member><function>maxdb_stmt_store_result</function> - Is not necessary for MaxDB.</member> - <member><function>maxdb_store_result</function> - Is not necessary for MaxDB.</member> - </simplelist> - <para> - Documentation for MaxDB can be found at - <link xlink:href="&url.maxdb.doc;">&url.maxdb.doc;</link>. - </para> - </section> - - <section xml:id="maxdb.requirements"> - &reftitle.required; - <para> - In order to have these functions available, you must compile PHP with - MaxDB support. Additionally, you must have the MaxDB SQLDBC runtime library - available to access the MaxDB server. - </para> - <para> - Documentation for MaxDB SQLDBC can be found at - <link xlink:href="&url.maxdb.doc;">&url.maxdb.doc;</link>. - </para> - <para> - Download the MaxDB SQLDBC package from - <link xlink:href="&url.maxdb.sdbc;">&url.maxdb.sdbc;</link>. - - </para> - </section> - - &reference.maxdb.configure; - - &reference.maxdb.ini; + <!-- FIXME: This extension apparently defines some classess that need to be + brought up2date with out OO markup --> <section xml:id='maxdb.classes'> &reftitle.classes; @@ -364,145 +305,7 @@ </section> </section> </section> - - <section xml:id="maxdb.resources"> - &reftitle.resources; - <para> - This extension defines resources. - </para> - </section> - - &reference.maxdb.constants; - - <section xml:id="maxdb.examples"> - &reftitle.examples; - <para> - All examples in the MaxDB PHP documentation use the HOTELDB demo database from MaxDB. More about this - database can be found at <link xlink:href="&url.maxdb.sampledb;">&url.maxdb.sampledb;</link>. - </para> - <para> - To use the examples in the MaxDB PHP documentation, you have to load the tutorial data into your database. - Then you have to set maxdb.default_db in &php.ini; to the database that contains the tutorial data. - </para> - <para> - This simple example shows how to connect, execute a query, print - resulting rows and disconnect from a MaxDB database. - <example> - <title>MaxDB extension overview example</title> - <programlisting role="php"> -<![CDATA[ -<?php -$link = maxdb_connect("localhost", "MONA", "RED", "DEMODB"); - -/* check connection */ -if (maxdb_connect_errno()) { - printf("Connect failed: %s\n", maxdb_connect_error()); - exit(); -} - -/* Performing SQL query */ -$query = "SELECT * FROM hotel.city"; -$result = maxdb_query($link, $query) or die("Query failed : " . maxdb_error()); - -/* Printing results in HTML */ -echo "<table>\n"; -while ($line = maxdb_fetch_array($result, MAXDB_ASSOC)) { - echo " <tr>\n"; - foreach ($line as $col_value) { - echo " <td>$col_value</td>\n"; - } - echo " </tr>\n"; -} -echo "</table>\n"; - -/* Free resultset */ -maxdb_free_result($result); - -/* Closing connection */ -maxdb_close($link); -?> -]]> - </programlisting> - </example> - </para> - <para> - The following example shows how to bind variables to a SELECT INTO statement. - <example> - <title>Example for use of SELECT INTO statements</title> - <programlisting role="php"> -<![CDATA[ -<?php -$link = maxdb_connect("localhost", "MONA", "RED", "DEMODB"); - -/* check connection */ -if (!$link) { - printf("Connect failed: %s\n", maxdb_connect_error()); - exit(); -} - -/* Performing SQL query */ -$stmt = maxdb_prepare ($link, "SELECT percentage INTO ? FROM hotel.countrylanguage where language = ?"); -if (!$stmt) { - printf ("Prepare failed: %s\n", maxdb_error($link)); -} - -$name = "Mbundu"; - -maxdb_stmt_bind_param($stmt, 'ds', $percentage, $name); -maxdb_stmt_execute($stmt); - -printf ("%f\n", $percentage); - -maxdb_stmt_close ($stmt); -?> -]]> - </programlisting> - </example> - </para> - <para> - The following example shows how to use MaxDB database procedures. - <example> - <title>Example fore using database procedures</title> - <programlisting role="php"> -<![CDATA[ -<?php -$link = maxdb_connect("localhost", "MONA", "RED", "DEMODB"); - -/* check connection */ -if (!$link) { - printf("Connect failed: %s\n", maxdb_connect_error()); - exit(); -} - -maxdb_report (MAXDB_REPORT_OFF); -maxdb_query($link,"DROP DBPROC test_proc"); -maxdb_report (MAXDB_REPORT_ERROR); - -$query = "create dbproc test_proc (INOUT e_text char(72)) AS select * from SYSDBA.DUAL; fetch into :e_text;"; - -maxdb_query($link, $query); - -/* Performing SQL query */ -$stmt = maxdb_prepare ($link, "CALL test_proc (?)"); -if (!$stmt) { - printf ("Prepare failed: %s\n", maxdb_error($link)); -} - -maxdb_stmt_bind_param($stmt, 's', $result); -maxdb_stmt_execute($stmt); - -printf ("%s\n", $result); - -maxdb_stmt_close ($stmt); -?> -]]> - </programlisting> - </example> - </para> - </section> - </partintro> - &reference.maxdb.entities.functions; </reference> @@ -527,3 +330,4 @@ vim: et tw=78 syn=sgml vi: ts=1 sw=1 --> +
« previous php.doc.cvs (#819) next »