[DOC-CVS] [doc-en] master: ODBC: PHP 8.4 resource to Object conversions (#5573)
[email protected] (Jordi Kroon via GitHub) Fri, 22 May 2026 17:30:53 +0000
| Newsgroups | php.doc.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: Jordi Kroon (jordikroon) Committer: GitHub (web-flow) Pusher: jordikroon Date: 2026-05-22T19:30:50+02:00 Commit: https://github.com/php/doc-en/commit/d705f166224fded16bf34a674b3e3690a083b34c Raw diff: https://github.com/php/doc-en/commit/d705f166224fded16bf34a674b3e3690a083b34c.diff ODBC: PHP 8.4 resource to Object conversions (#5573) * Add Odbc\Connection and Odbc\Result classes Co-authored-by: Louis-Arnaud <[email protected]> Changed paths: A reference/uodbc/odbc.connection.xml A reference/uodbc/odbc.result.xml M reference/uodbc/book.xml M reference/uodbc/versions.xml Diff: diff --git a/reference/uodbc/book.xml b/reference/uodbc/book.xml index 763bb3d19a13..22939998c79e 100644 --- a/reference/uodbc/book.xml +++ b/reference/uodbc/book.xml @@ -9,24 +9,24 @@ <!-- {{{ preface --> <preface xml:id="intro.uodbc"> &reftitle.intro; - <para> + <simpara> In addition to normal ODBC support, the Unified ODBC functions in PHP allow you to access several databases that have borrowed the semantics of the ODBC API to implement their own API. Instead of maintaining multiple database drivers that were all nearly identical, these drivers have been unified into a single set of ODBC functions. - </para> - <para> + </simpara> + <simpara> The following databases are supported by the Unified ODBC functions: <link xlink:href="&url.adabas;">Adabas D</link>, <link xlink:href="&url.ibmdb2;">IBM DB2</link>, <link xlink:href="&url.iodbc;">iODBC</link>, <link xlink:href="&url.solid;">Solid</link>, and <link xlink:href="&url.sybase;">Sybase SQL Anywhere</link>. - </para> + </simpara> <note> - <para> + <simpara> With the exception of iODBC, there is no ODBC involved when connecting to the above databases. The functions that you use to speak natively to them just happen to share the same @@ -36,15 +36,17 @@ is available at <link xlink:href="&url.iodbc;">www.iodbc.org</link> with the alternative unixODBC available at <link xlink:href="&url.unixodbc;">www.unixodbc.org</link>. - </para> + </simpara> </note> </preface> <!-- }}} --> - + &reference.uodbc.setup; &reference.uodbc.constants; &reference.uodbc.reference; + &reference.uodbc.odbc.connection; + &reference.uodbc.odbc.result; </book> <!-- Keep this comment at the end of the file diff --git a/reference/uodbc/odbc.connection.xml b/reference/uodbc/odbc.connection.xml new file mode 100644 index 000000000000..9d354e6eda6c --- /dev/null +++ b/reference/uodbc/odbc.connection.xml @@ -0,0 +1,56 @@ +<?xml version="1.0" encoding="utf-8"?> +<reference xmlns="http://docbook.org/ns/docbook" xml:id="class.odbc-connection" role="class"> + <title>The Odbc\Connection class</title> + <titleabbrev>Odbc\Connection</titleabbrev> + + <partintro> + + <!-- {{{ Odbc\Connection intro --> + <section xml:id="odbc-connection.intro"> + &reftitle.intro; + <simpara> + A fully opaque class which replaces an <literal>odbc_connection</literal> &resource; as of PHP 8.4.0. + </simpara> + </section> + <!-- }}} --> + + <section xml:id="odbc-connection.synopsis"> + &reftitle.classsynopsis; + + <!-- {{{ Synopsis --> + <packagesynopsis> + <package>Odbc</package> + + <classsynopsis class="class"> + <ooclass> + <classname>Connection</classname> + </ooclass> + </classsynopsis> + </packagesynopsis> + <!-- }}} --> + + </section> + + </partintro> + +</reference> +<!-- Keep this comment at the end of the file + Local variables: + mode: sgml + sgml-omittag:t + sgml-shorttag:t + sgml-minimize-attributes:nil + sgml-always-quote-attributes:t + sgml-indent-step:1 + sgml-indent-data:t + indent-tabs-mode:nil + sgml-parent-document:nil + sgml-default-dtd-file:"~/.phpdoc/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 + --> diff --git a/reference/uodbc/odbc.result.xml b/reference/uodbc/odbc.result.xml new file mode 100644 index 000000000000..6aabfd49e362 --- /dev/null +++ b/reference/uodbc/odbc.result.xml @@ -0,0 +1,56 @@ +<?xml version="1.0" encoding="utf-8"?> +<reference xmlns="http://docbook.org/ns/docbook" xml:id="class.odbc-result" role="class"> + <title>The Odbc\Result class</title> + <titleabbrev>Odbc\Result</titleabbrev> + + <partintro> + + <!-- {{{ Odbc\Result intro --> + <section xml:id="odbc-result.intro"> + &reftitle.intro; + <simpara> + A fully opaque class which replaces an <literal>odbc_result</literal> &resource; as of PHP 8.4.0. + </simpara> + </section> + <!-- }}} --> + + <section xml:id="odbc-result.synopsis"> + &reftitle.classsynopsis; + + <!-- {{{ Synopsis --> + <packagesynopsis> + <package>Odbc</package> + + <classsynopsis class="class"> + <ooclass> + <classname>Result</classname> + </ooclass> + </classsynopsis> + </packagesynopsis> + <!-- }}} --> + + </section> + + </partintro> + +</reference> +<!-- Keep this comment at the end of the file + Local variables: + mode: sgml + sgml-omittag:t + sgml-shorttag:t + sgml-minimize-attributes:nil + sgml-always-quote-attributes:t + sgml-indent-step:1 + sgml-indent-data:t + indent-tabs-mode:nil + sgml-parent-document:nil + sgml-default-dtd-file:"~/.phpdoc/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 + --> diff --git a/reference/uodbc/versions.xml b/reference/uodbc/versions.xml index 1267dd0a9bf4..d126e36218ee 100644 --- a/reference/uodbc/versions.xml +++ b/reference/uodbc/versions.xml @@ -4,6 +4,11 @@ Do NOT translate this file --> <versions> + <!-- Classes --> + <function name="odbc\connection" from="PHP 8 >= 8.4.0"/> + <function name="odbc\result" from="PHP 8 >= 8.4.0"/> + + <!-- Functions --> <function name="odbc_autocommit" from="PHP 4, PHP 5, PHP 7, PHP 8"/> <function name="odbc_binmode" from="PHP 4, PHP 5, PHP 7, PHP 8"/> <function name="odbc_close" from="PHP 4, PHP 5, PHP 7, PHP 8"/>