PHP and Informix?
Posted in 2011
Topics: General Discussion
Dear Informixers, it's been a long time since I've been active in this group. Our IDS server is just running smoothly, so I didn't need assistance. But now something new has come up: We have a web application in_house that our department wants to participate in. The application is running under PHP5 on a Linux server. This application now needs access to data in our IDS 11.50 server. I have no PHP knowledge, and the developer of the application has no Informix knowledge. So I'm looking for a HowTo to implement PHP access to our data, but the search has been very frustrating. There is a PDO_IBM driver available for which there is practically no documentation available, at least as far as Informix acess is concerned. It seems that this requires a DB2 client on the PHP machine and DRDA on the IDS server, but I have never worked with DRDA and would like to avoid that if possible. There is also a PDO_Informix driver but that seems to be not actively supported any more and doesn't run with current versions of PHP. Does anyone hear have a successful connection from PHP to IDS 11.50 and can give me step-by-step instructions about how to implement this? Regards, Richard
You are correct, the PDO_Informix connection is not being developed going forward and I have been told that the PDO_IBM is the better choice. Enabling DRDA in Informix, for versions 11.10 and later, is easy. Just add a line to your SQLHOSTS file that names the protocol drsoctcp or drtlitcp (as appropriate to your platform) and include that connection name in the DBSERVERALIASES list. For the client side, you can download the same IBM driver that is used for DB2 and install that on the PCs that need access to the database and configure a connection to the database server's drda alias. Art Art S. Kagel Advanced DataTools (www.advancedatatools.com) Blog: http://informix-myview.blogspot.com/ Disclaimer: Please keep in mind that my own opinions are my own opinions and do not reflect on my employer, Advanced DataTools, the IIUG, nor any other organization with which I am associated either explicitly, implicitly, or by inference. Neither do those opinions reflect those of other individuals affiliated with any entity with which I am affiliated nor those of the entities themselves. On Mon, Mar 28, 2011 at 11:47 AM, rspitzmd < Richard.Spitz@med.uni-muenchen.de> wrote: > Dear Informixers, > > it's been a long time since I've been active in this group. Our IDS > server is just running smoothly, so I didn't need assistance. But now > something new has come up: > > We have a web application in_house that our department wants to > participate in. The application is running under PHP5 on a Linux > server. > > This application now needs access to data in our IDS 11.50 server. I > have no PHP knowledge, and the developer of the application has no > Informix knowledge. So I'm looking for a HowTo to implement PHP access > to our data, but the search has been very frustrating. > > There is a PDO_IBM driver available for which there is practically no > documentation available, at least as far as Informix acess is > concerned. It seems that this requires a DB2 client on the PHP machine > and DRDA on the IDS server, but I have never worked with DRDA and > would like to avoid that if possible. There is also a PDO_Informix > driver but that seems to be not actively supported any more and > doesn't run with current versions of PHP. > > Does anyone hear have a successful connection from PHP to IDS 11.50 > and can give me step-by-step instructions about how to implement this? > > Regards, Richard > _______________________________________________ > Informix-list mailing list > Informix-list@iiug.org > http://www.iiug.org/mailman/listinfo/informix-list >
Am 28.03.2011 17:47 schrieb rspitzmd: [...] > Does anyone hear have a successful connection from PHP to IDS 11.50 > and can give me step-by-step instructions about how to implement this? Hi Richard, take a look at the Redbook "IBM Informix Developer's Handbook" at <http://www.redbooks.ibm.com/redbooks/SG247884/wwhelp/wwhimpl/java/html/wwhelp.htm>. There is a whole chapter on this subject. HTH and best regards Christian