<legend id='E2CVs'><style id='E2CVs'><dir id='E2CVs'><q id='E2CVs'></q></dir></style></legend>
    <i id='E2CVs'><tr id='E2CVs'><dt id='E2CVs'><q id='E2CVs'><span id='E2CVs'><b id='E2CVs'><form id='E2CVs'><ins id='E2CVs'></ins><ul id='E2CVs'></ul><sub id='E2CVs'></sub></form><legend id='E2CVs'></legend><bdo id='E2CVs'><pre id='E2CVs'><center id='E2CVs'></center></pre></bdo></b><th id='E2CVs'></th></span></q></dt></tr></i><div id='E2CVs'><tfoot id='E2CVs'></tfoot><dl id='E2CVs'><fieldset id='E2CVs'></fieldset></dl></div>
  • <tfoot id='E2CVs'></tfoot>
    • <bdo id='E2CVs'></bdo><ul id='E2CVs'></ul>

        <small id='E2CVs'></small><noframes id='E2CVs'>

        如何使连接池在 PHP-CGI PDO iSeries Access UnixODBC 连接上工作?

        时间:2024-05-11
            <bdo id='ZlgcJ'></bdo><ul id='ZlgcJ'></ul>
            <i id='ZlgcJ'><tr id='ZlgcJ'><dt id='ZlgcJ'><q id='ZlgcJ'><span id='ZlgcJ'><b id='ZlgcJ'><form id='ZlgcJ'><ins id='ZlgcJ'></ins><ul id='ZlgcJ'></ul><sub id='ZlgcJ'></sub></form><legend id='ZlgcJ'></legend><bdo id='ZlgcJ'><pre id='ZlgcJ'><center id='ZlgcJ'></center></pre></bdo></b><th id='ZlgcJ'></th></span></q></dt></tr></i><div id='ZlgcJ'><tfoot id='ZlgcJ'></tfoot><dl id='ZlgcJ'><fieldset id='ZlgcJ'></fieldset></dl></div>

            <small id='ZlgcJ'></small><noframes id='ZlgcJ'>

            • <legend id='ZlgcJ'><style id='ZlgcJ'><dir id='ZlgcJ'><q id='ZlgcJ'></q></dir></style></legend>

                <tbody id='ZlgcJ'></tbody>

              1. <tfoot id='ZlgcJ'></tfoot>
                • 本文介绍了如何使连接池在 PHP-CGI PDO iSeries Access UnixODBC 连接上工作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我正在尝试使用 PHP/PDO 和名为 iSeries Access for Linux 的 UnixODBC 驱动程序使连接池工作.

                  I am trying to get connection pooling working using PHP/PDO with a UnixODBC driver called iSeries Access for Linux.

                  我没有在我的 PDO 构造函数中设置 PDO::ATTR_PERSISTENT,因为我想使用池而不是持久性(我在 PHP-CGI 环境中).

                  I do not set the PDO::ATTR_PERSISTENT in my PDO constructor as I want to use pooling and not persistence (I am in a PHP-CGI environment).

                  使用 http://www 的连接池"部分.ibm.com/developerworks/systems/library/es-linux_bestpract.html我已经放了

                  Pooling = Yes
                  

                  在我的 odbc.ini 和

                  in my odbc.ini and

                  CPTimeout = 600 
                  

                  在我的 odbcinst.ini 中

                  in my odbcinst.ini

                  但是,ODBC 驱动程序似乎不是连接池,因为每次页面刷新都会生成与正在建立的传入连接相关的 CPIAD09 消息.

                  However, it seems that the ODBC driver is not connection pooling because every page refresh generates the CPIAD09 related message of an incoming connection being made.

                  这是我的完整 ODBC 配置文件:

                  Here are my full ODBC configuration files:

                  ==== odbc.ini ====
                  [AS400]
                  Description             = Production AS/400 Database
                  Driver                  = iSeries Access ODBC Driver
                  System                  = XXX.XXX.X.X
                  UserID                  = XXXXXXXX
                  Password                = XXXXXXXX
                  Naming                  = 0
                  DefaultLibraries        = USERLIB, BPCSF, ADV, WEB, RITAUSR
                  Database                =
                  ConnectionType          = 0
                  CommitMode              = 2
                  ExtendedDynamic         = 0
                  DefaultPkgLibrary       = QGPL
                  DefaultPackage          = A/DEFAULT(IBM),2,0,1,0,512
                  AllowDataCompression    = 1
                  LibraryView             = 0
                  AllowUnsupportedChar    = 0
                  ForceTranslation        = 0
                  Trace                   = 0
                  DSN                     = AS400
                  Pooling                 = Yes
                  

                  ==== odbcinst.ini ====
                  [iSeries Access ODBC Driver]
                  Description     = iSeries Access for Linux ODBC Driver
                  Driver          = /opt/ibm/iSeriesAccess/lib/libcwbodbc.so
                  Setup           = /opt/ibm/iSeriesAccess/lib/libcwbodbcs.so
                  NOTE1           = If using unixODBC 2.2.11 or later and you want the 32 and 64-bit ODBC drivers to share DSN's,
                  NOTE2           = the following Driver64/Setup64 keywords will provide that support.
                  Driver64        = /opt/ibm/iSeriesAccess/lib64/libcwbodbc.so
                  Setup64         = /opt/ibm/iSeriesAccess/lib64/libcwbodbcs.so
                  Threading       = 2
                  DontDLClose     = 1
                  UsageCount      = 1
                  CPTimeout       = 600
                  

                  推荐答案

                  Pooling         = Yes
                  

                  这需要在您的 odbcinst.ini 而不是您的 odbc.ini 文件中的 [ODBC] 下进行

                  This needs to go under [ODBC] in you odbcinst.ini and NOT your odbc.ini file

                  CPTimeout       = 600
                  

                  把它放在你的 odbc.ini 中

                  Put this in your odbc.ini

                  这篇关于如何使连接池在 PHP-CGI PDO iSeries Access UnixODBC 连接上工作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:如何在不等待结果的情况下将 SQL 查询发送到 PHP 中的数据库 下一篇:AS400/DB2 中的分页查询(SQL)

                  相关文章

                  <tfoot id='NXdtX'></tfoot>

                  1. <legend id='NXdtX'><style id='NXdtX'><dir id='NXdtX'><q id='NXdtX'></q></dir></style></legend>

                      • <bdo id='NXdtX'></bdo><ul id='NXdtX'></ul>
                    1. <small id='NXdtX'></small><noframes id='NXdtX'>

                      <i id='NXdtX'><tr id='NXdtX'><dt id='NXdtX'><q id='NXdtX'><span id='NXdtX'><b id='NXdtX'><form id='NXdtX'><ins id='NXdtX'></ins><ul id='NXdtX'></ul><sub id='NXdtX'></sub></form><legend id='NXdtX'></legend><bdo id='NXdtX'><pre id='NXdtX'><center id='NXdtX'></center></pre></bdo></b><th id='NXdtX'></th></span></q></dt></tr></i><div id='NXdtX'><tfoot id='NXdtX'></tfoot><dl id='NXdtX'><fieldset id='NXdtX'></fieldset></dl></div>