<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <title>Runtime Configuration</title> </head> <body><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="odbc.installation.html">Installation</a></div> <div class="next" style="text-align: right; float: right;"><a href="uodbc.resources.html">Resource Types</a></div> <div class="up"><a href="uodbc.setup.html">Installing/Configuring</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div><hr /><div id="odbc.configuration" class="section"> <h2 class="title">Runtime Configuration</h2> <p class="simpara"> The behaviour of these functions is affected by settings in <var class="filename">php.ini</var>. </p> <p class="para"> <table class="doctable table"> <caption><strong>Unified ODBC Configuration Options</strong></caption> <thead> <tr> <th>Name</th> <th>Default</th> <th>Changeable</th> <th>Changelog</th> </tr> </thead> <tbody class="tbody"> <tr> <td><a href="odbc.configuration.html#ini.uodbc.default-db" class="link">odbc.default_db</a> *</td> <td>NULL</td> <td>PHP_INI_ALL</td> <td class="empty"> </td> </tr> <tr> <td><a href="odbc.configuration.html#ini.uodbc.default-user" class="link">odbc.default_user</a> *</td> <td>NULL</td> <td>PHP_INI_ALL</td> <td class="empty"> </td> </tr> <tr> <td><a href="odbc.configuration.html#ini.uodbc.default-pw" class="link">odbc.default_pw</a> *</td> <td>NULL</td> <td>PHP_INI_ALL</td> <td class="empty"> </td> </tr> <tr> <td><a href="odbc.configuration.html#ini.uodbc.allow-persistent" class="link">odbc.allow_persistent</a></td> <td>"1"</td> <td>PHP_INI_SYSTEM</td> <td class="empty"> </td> </tr> <tr> <td><a href="odbc.configuration.html#ini.uodbc.check-persistent" class="link">odbc.check_persistent</a></td> <td>"1"</td> <td>PHP_INI_SYSTEM</td> <td class="empty"> </td> </tr> <tr> <td><a href="odbc.configuration.html#ini.uodbc.max-persistent" class="link">odbc.max_persistent</a></td> <td>"-1"</td> <td>PHP_INI_SYSTEM</td> <td class="empty"> </td> </tr> <tr> <td><a href="odbc.configuration.html#ini.uodbc.max-links" class="link">odbc.max_links</a></td> <td>"-1"</td> <td>PHP_INI_SYSTEM</td> <td class="empty"> </td> </tr> <tr> <td><a href="odbc.configuration.html#ini.uodbc.defaultlrl" class="link">odbc.defaultlrl</a></td> <td>"4096"</td> <td>PHP_INI_ALL</td> <td class="empty"> </td> </tr> <tr> <td><a href="odbc.configuration.html#ini.uodbc.defaultbinmode" class="link">odbc.defaultbinmode</a></td> <td>"1"</td> <td>PHP_INI_ALL</td> <td class="empty"> </td> </tr> <tr> <td>odbc.default_cursortype</td> <td>"3"</td> <td>PHP_INI_ALL</td> <td>Available as of PHP 5.3.0</td> </tr> </tbody> </table> <blockquote class="note"><p><strong class="note">Note</strong>: <span class="simpara"> Entries marked with * are not implemented yet. </span> </p></blockquote> For further details and definitions of the PHP_INI_* modes, see the <a href="configuration.changes.modes.html" class="xref">Where a configuration setting may be set</a>. </p> <p class="para">Here's a short explanation of the configuration directives.</p> <p class="para"> <dl> <dt id="ini.uodbc.default-db"> <span class="term"> <em><code class="parameter">odbc.default_db</code></em> <span class="type"><a href="language.types.string.html" class="type string">string</a></span> </span> <dd> <p class="para"> ODBC data source to use if none is specified in <span class="function"><a href="function.odbc-connect.html" class="function">odbc_connect()</a></span> or <span class="function"><a href="function.odbc-pconnect.html" class="function">odbc_pconnect()</a></span>. </p> </dd> </dt> <dt id="ini.uodbc.default-user"> <span class="term"> <em><code class="parameter">odbc.default_user</code></em> <span class="type"><a href="language.types.string.html" class="type string">string</a></span> </span> <dd> <p class="para"> User name to use if none is specified in <span class="function"><a href="function.odbc-connect.html" class="function">odbc_connect()</a></span> or <span class="function"><a href="function.odbc-pconnect.html" class="function">odbc_pconnect()</a></span>. </p> </dd> </dt> <dt id="ini.uodbc.default-pw"> <span class="term"> <em><code class="parameter">odbc.default_pw</code></em> <span class="type"><a href="language.types.string.html" class="type string">string</a></span> </span> <dd> <p class="para"> Password to use if none is specified in <span class="function"><a href="function.odbc-connect.html" class="function">odbc_connect()</a></span> or <span class="function"><a href="function.odbc-pconnect.html" class="function">odbc_pconnect()</a></span>. </p> </dd> </dt> <dt id="ini.uodbc.allow-persistent"> <span class="term"> <em><code class="parameter">odbc.allow_persistent</code></em> <span class="type"><a href="language.types.boolean.html" class="type boolean">boolean</a></span> </span> <dd> <p class="para"> Whether to allow persistent ODBC connections. </p> </dd> </dt> <dt id="ini.uodbc.check-persistent"> <span class="term"> <em><code class="parameter">odbc.check_persistent</code></em> <span class="type"><a href="language.types.boolean.html" class="type boolean">boolean</a></span> </span> <dd> <p class="para"> Check that a connection is still valid before reuse. </p> </dd> </dt> <dt id="ini.uodbc.max-persistent"> <span class="term"> <em><code class="parameter">odbc.max_persistent</code></em> <span class="type"><a href="language.types.integer.html" class="type integer">integer</a></span> </span> <dd> <p class="para"> The maximum number of persistent ODBC connections per process. </p> </dd> </dt> <dt id="ini.uodbc.max-links"> <span class="term"> <em><code class="parameter">odbc.max_links</code></em> <span class="type"><a href="language.types.integer.html" class="type integer">integer</a></span> </span> <dd> <p class="para"> The maximum number of ODBC connections per process, including persistent connections. </p> </dd> </dt> <dt id="ini.uodbc.defaultlrl"> <span class="term"> <em><code class="parameter">odbc.defaultlrl</code></em> <span class="type"><a href="language.types.integer.html" class="type integer">integer</a></span> </span> <dd> <p class="para"> Handling of LONG fields. Specifies the number of bytes returned to variables. </p> <span class="simpara">When an <span class="type"><a href="language.types.integer.html" class="type integer">integer</a></span> is used, the value is measured in bytes. Shorthand notation, as described in <a href="faq.using.html#faq.using.shorthandbytes" class="link">this FAQ</a>, may also be used. </span> </dd> </dt> <dt id="ini.uodbc.defaultbinmode"> <span class="term"> <em><code class="parameter">odbc.defaultbinmode</code></em> <span class="type"><a href="language.types.integer.html" class="type integer">integer</a></span> </span> <dd> <p class="para"> Handling of binary data. </p> </dd> </dt> <dt id="ini.uodbc.defaultcursortype"> <span class="term"> <em><code class="parameter">odbc.default_cursortype</code></em> <span class="type"><a href="language.types.integer.html" class="type integer">integer</a></span> </span> <dd> <p class="para"> Controls the ODBC cursor model. Possible values are <strong><code>SQL_CURSOR_FORWARD_ONLY</code></strong>, <strong><code>SQL_CURSOR_KEYSET_DRIVEN</code></strong>, <strong><code>SQL_CURSOR_DYNAMIC</code></strong> and <strong><code>SQL_CURSOR_STATIC</code></strong> (default). </p> </dd> </dt> </dl> </p> </div><hr /><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="odbc.installation.html">Installation</a></div> <div class="next" style="text-align: right; float: right;"><a href="uodbc.resources.html">Resource Types</a></div> <div class="up"><a href="uodbc.setup.html">Installing/Configuring</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div></body></html>