Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.tools -> Re: Problem of connection Oracle with PHP4

Re: Problem of connection Oracle with PHP4

From: Aca Vasic <acko_at_ni.ac.yu>
Date: Thu, 17 May 2001 14:09:39 +0200
Message-ID: <9e0euf$8n8$1@zmaj.etf.bg.ac.yu>

"Bernard Marty" <bmarty_at_club-internet.fr> wrote in message news:9d1m04$rt7$1_at_front5.grolier.fr...
> After a migration from php3 to PHP4, my application doesn't manage to
> connect to
> the database defined in the TNSNAMES.ora
> Message : _oci_open_server:ORA-12154 : TNS:Symbolic adress can not be
> resolved
> Somebody can help me please???
> Thanks
>
>

I had the same kind of problem and my solution was to hardcode connection string into php script, something like this:

$connectstring =
"(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(COMMUNITY=tcp.world)".

                "(PROTOCOL=TCP)(Host=myhost)(Port=1521)))".
                "(CONNECT_DATA = (SID = oracle)))";
Received on Thu May 17 2001 - 07:09:39 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US