Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ZendServer 6.1.0 on Windows 2012 configuration for local and remote DB

User_BP06JOct 21 2013 — edited Oct 25 2013

I have installed Zend Server 6.1.0 (PHP 5.4.16 - Apache 2.2.22) on a Win 2012 64 bit server. I need to connect both to a local Oracle 12c (64 bit) server, and to a remote Oracle DB.

Zend Server already contains Oracle client libraries (orannzsbb11.dll, oraocci11.dll, oraociei11.dll, orasql11.dll) and I am able to connect to both the local Oracle DB and the remote one, but only using the full connect identifier inside the PHP script, e.g.

  $tns = "(DESCRIPTION =
              (ADDRESS=(PROTOCOL = TCP)(HOST = XXX0001)(PORT = 1521))
              (CONNECT_DATA=(SERVER = DEDICATED)(SID = ORAXXX)))";
  $c = oci_connect("XXXX", "XXXX", $tns);

What I would like is to go through the tnsnames.ora file. I tried installing the full 32 bit Oracle client and also the 32 bit Instant client, but I was not able to make PHP go through the tnsnames.ora. I have set the PATH variable to contain the client libraries in front, and also tried setting the TNS_ADMIN env var, but I was not able to make PHP see the tnsnames.ora.

Do you know how I should set up things to make it work?

Thanks!

This post has been answered by User_BP06J on Oct 22 2013
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 22 2013
Added on Oct 21 2013
3 comments
2,100 views