ZF-11940: Problem with connecting to IDS with pdo_ibm driver


I am having a problem with acquiring a new connection to an IDS database using pdo_ibm driver. Connection string: "ibm: DRIVER={IBM DB2 ODBC DRIVER};DATABASE=zbo; HOSTNAME=IP_ADDR;PORT=9088;PROTOCOL=TCPIP; " I get an error:

SQLSTATE=08001, SQLDriverConnect: -30081 [IBM][CLI Driver] SQL30081N A communication error has been detected. Communication protocol being used: "TCP/IP". Communication API being used: "SOCKETS". Location where the error was detected: "IP_ADDR". Communication function detecting the error: "recv". Protocol specific error code(s): "", "", "0". SQLSTATE=0800 which I was unable to decipher having the available documentation. Database configuration is also limited due to the fact that it is constantly working in production mode.

I have managed to come up with a workaround by using this connection string "informix: host=IP_ADDR; service=9088; database=zbo; server=db; protocol=onsoctcp; DB_LOCALE=pl_PL.1250; Client_Locale=pl_pl.1250" and setting specifically IDS in Zend_Db_Adapter_Pdo_Ibm:_connect()

I would ask to You, for the future version of Zend, to make Zend\Db\Adapter\Pdo\Ibm\Ids.php a seprate Zend_Db_Adapter_Pdo_Abstract with "informix" as a _pdoType.


If you are prepared to sign the CLA (…) and provide a patch, I'm happy to review it.