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: Help me please.

Re: Help me please.

From: Ron Reidy <rereidy_at_indra.com>
Date: Wed, 24 Oct 2001 20:04:42 -0600
Message-ID: <3BD7733A.EA69E245@indra.com>


FaheemRao wrote:
>
> Ok To my thinking that the Standard Port at which Oracle Listners listen is 1521,
> Please Check the Port number in your Code.
>
> Faheem Rao
>
> "Sybrand Bakker" <postbus_at_sybrandb.demon.nl> wrote in message news:<tte35tk9e1m542_at_corp.supernews.com>...
> > Aaaaaaaaaarrrrrrrrrrghhhh
> >
> >
> > Connection conn =
> > DriverManager.getConnection("dbc:oracle:thin:@localhost:1521:sid","username"
> > ,"password");
> >
> > should read
> > Connection conn =
> > DriverManager.getConnection("*J*dbc:oracle:thin:@localhost:1521:sid","userna
> > me","password");
> >
> > without the asterixes of course and in lower case
> > either your typing or your eyesight is very very troubled.
> >
> > PLEASE PLEASE verify *CAREFULLY* your own code
> > and don't post *EVERY* error you get
> > or buy glasses or follow a typing course,
> > as this is the *second* time in *very short* succession you are asking for
> > assistance in typing errors
> >
> > Regards
> >
> > Sybrand Bakker
> > Senior Oracle DBA
> >
> >
> >
> >
> >
> >
> > "ftp" <shyan_at_cse.cuhk.edu.hk> wrote in message
> > news:9r703v$aua$1_at_eng-ser1.erg.cuhk.edu.hk...
> > > Sybrand Bakker <postbus_at_sybrandb.demon.nl> wrote:
> > >
> > > > "ftp" <shyan_at_cse.cuhk.edu.hk> wrote in message
> > > > news:9r6q1v$7d2$3_at_eng-ser1.erg.cuhk.edu.hk...
> > > >> I copy the folloiwng program from oracle hompage
> > > >> http://technet.oracle.com/doc/java.815/a64685/getsta3.htm#1001200
> > > >>
> > > >> import java.sql.*;
> > > >> import oracle.jdbc.driver.*;
> > > >>
> > > >> class JDBCVersion
> > > >> {
> > > >> public static void main (String args [])
> > > >> throws SQLException
> > > >> {
> > > >> // Load the Oracle JDBC driver
> > > >> DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
> > > >> Connection conn =
> > > >>
> > > >
> > DriverManager.getConnection("jdbc:oracle:thin:@:1588localhost:sid","username
> > > > ","password");
> > > >>
> > > >> // Create Oracle DatabaseMetaData object
> > > >> DatabaseMetaData meta = conn.getMetaData ();
> > > >>
> > > >> // gets driver info:
> > > >> System.out.println("JDBC driver version is " +
> > meta.getDriverVersion());
> > > >> }
> > > >> }
> > > >>
> > > >> sid is the sid of my database. username and password is the login
> > username
> > > >> and password.
> > > >> I haven't changed the port nubmer. Is it true that the default port is
> > > >> 1588?
> > > >>
> > > >> When I run the program, the following error occur:
> > > >> java.sql.SQLException: Io exception: The Network Adapter could not
> > > >> establish the connection
> > > >> at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java)
> > > >> at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java)
> > > >> at
> > > >> oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java)
> > > >> at
> > > >>
> > oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java)
> > > >> at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java)
> > > >> at java.sql.DriverManager.getConnection(Compiled Code)
> > > >> at java.sql.DriverManager.getConnection(DriverManager.java:126)
> > > >> at JDBCVersion.main(JDBCVersion.java:11)
> > > >>
> > > >> How can I solve the problem?
> > > >>
> > > >> Very urgent, if possible, please reply me by e-mail.
> > > >> Thank you very much!
> > > >>
> > > >> --
> > >
> > >
> > > Sorry for any inconvenient. However, in my situation, time is a very
> > > importanat factor. I cannot waste a lot of time to see the documentation.
> > > My requirement is that I can connect to Oracle, no other things.
> > > I'm not a DBA or DBO to Oracle. I'm just a student. I must setup my Oracle
> > > as quicly as possible in order to start my real work. Installation of
> > > Oracle is only a preparation step in my project. I don't want to waste a
> > > lot of time on it.
> > > Hoping that all of you can understand me.
> > > Sorry for any inconvenient.
> > >
> > > At last, I use OCI driver in stead of thin driver to connect to the
> > > database.
> > > Can anyone tell me why I can't use thin driver?
> > > What's wrong in this line?
> > > Connection conn =
> > >
> > DriverManager.getConnection("dbc:oracle:thin:@localhost:1521:sid","username"
> > ,"password");
> > >
> > > > Could you *PLEASE* stop posting your questions to every Oracle
> > newsgroup, or
> > > > crosspost if you think you really need to do it. You're wasting bandwith
> > and
> > > > you won't get a bigger and better audience as most people responding
> > here
> > > > monitor all groups. Also, when you post in succession, no one will see
> > the
> > > > answers in other newsgroups and see the request has already been
> > answered.
> >
> > > > Regards,
> >
> > > > Sybrand Bakker
> > > > Senior Oracle DBA
> > >
> > >
> > >
> > >
> > > --

The original guy goes into the killfile...tooo busy with my life to bother with his incompetence and arogance.

-- 
Ron Reidy
Oracle DBA
Reidy Consulting, L.L.C.
Received on Wed Oct 24 2001 - 21:04:42 CDT

Original text of this message

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