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

Home -> Community -> Usenet -> c.d.o.server -> Re: Problem connecting to Oracle from PHP script.

Re: Problem connecting to Oracle from PHP script.

From: Chris <chrism_at_cs.dal.ca>
Date: Sat, 10 Feb 2001 18:37:31 -0400
Message-ID: <964fne$m93$1@News.Dal.Ca>

I thought that if you didn't specify which database to connect to, it would of used the default which is defined in $ORACLE_SID. I just enter a login and pass in SQLPLUS, so I think it just uses the default database $ORACLE_SID. I would assume logon on form within PHP would do the same.

Is there a way to see if SQLPLUS changes the environment variable $ORACLE_SID. I am just a undergrad user of the system, so it may change the default database on that fact in SQLPLUS.

"DvE" <d.van.es_at_xs4all.nl> wrote in message news:96337d$fnn$1_at_news1.xs4all.nl...
>
> Did you enter the correct sid?
>
> "Chris" <chrism_at_cs.dal.ca> wrote in message
 news:96137g$9e8$1_at_News.Dal.Ca...
> > I have a solaris server that has apache and php and Oracle 7 installed
 on
 it
> > (all within a localhost)
> >
> > Problem connecting to Oracle with PHP,
> > Return Error:
> > -------------------
> > Warning: Oracle: Connection Failed: ORA-01034: ORACLE not available in
> > /users/cs/chrism/public_html/hs~test.phtml on line 8
> > -------------------
> >
> > The Php module on the hosts apache was configutured with Oracle support:
> > '--with-oracle'
> > $ORACLE_HOME = /opt/oracle/app/oracle/product/733 which is correct
> >
> > PHP script function:
> >
> > Ora_Logon open an Oracle connection
> >
> > int ora_logon (string user, string password); /*I have an db account and
 I
> > put the right user and pass in*/
> >
> > -----------------------------------
> > Does anyone have any Reasons as to why I cann't connect?
> > Note: I can use SQLPLUS with Oracle no problems.
> >
> >
> >
> >
>
>
Received on Sat Feb 10 2001 - 16:37:31 CST

Original text of this message

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