tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Huaxin <hxzh...@cs.ualberta.ca>
Subject Re: JSP page to Oracle with Tomcat all files
Date Mon, 18 Sep 2000 17:39:35 GMT
Just curious on the URL you've mentioned, how can you
append the userid and passwd after the jdbc:oracle:thin:@xxx.x things?

i know the format for cloud DB, i am wondering it for oracle only

On Tue, 18 Sep 2001, P.Miller wrote:

> Hi Peter,
>
> I put the IP-Adress after the '@' and use the 'thin' driver instead of
> the 'oci8'.
> Also you have to put the port# on which the Listener waits for calls.
> In most cases it's the 1521.
> And the name of your Database ORCL or something else
> So the string should look like :
> jdbc:oracle:thin:@xxx.xxx.xxx.xxx:1521:ORCL
> plus userid and password.
>
> Hth
>
> Peter
> >
> > Not sure why all the attachments did not come through but here goes
> > again:
> >
> > Tomcat 4.0 b7
> > Solaris 8
> > Oracle 8.1.7
> >
> > I am trying to perform a Oracle DB query from a jsp page. I have included
> > the web.xml file the jsp page "fwtst.jsp" and the error message I am
> > having returned to me from the query.
> > I believe the problem is that I do not know how to make system
> > environments known to JSP or Tomcat. This is because of the error I am
> > getting which is "javax.servlet.ServletException: ORA-12154: TNS:could
> > not resolve service name  at so on and so on"
> >
> > >From my Oracle experience I know this error typically mean you are using
> > the wrong  DB alias or  an environment variable such as ORACLE_HOME or
> > TNS_ADMIN is not set or is incorrect.
> >
> > Before I start Tomcat I have checked and re-checked my ability to run
> > sqlplus and connect to the DB but from the JSP page I cannot.
> >
> > My questions are
> > Can I set environmental variables such as ORACLE_HOME in the JSP.  If so
> > how? please give a short example
> > Can I use one of  Tomcat's files such as web.xml or server. xml ??
> > Can I use one of the web-appliation files such as web.xml??
> >
> > Thanks
> > Pete
> >
> >   ------------------------------------------------------------------------
> >                    Name: files.tar
> >    files.tar       Type: Unix Tape Archive (application/x-tar)
> >                Encoding: base64
> >             Description: filename="files.tar"
>


Mime
View raw message