Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: CallableStatement Problem with Oracle database
Hello!
> try
> {
> System.out.println("Getting a connection.");
> Connection objConn =
> DbaseManager.getManager().getConnection();
Why don't you use DriverManager? And where do you specify login and password?
Exp:
public static void OracleConnect(){
// 1.
try{ DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver()); } catch (SQLException sqle){ System.out.println("ERROR: Bad Oracle JDBC driver!"); } // try // 2. try{ conn = DriverManager.getConnection("jdbc:oracle:thin:" + "@"+"your_site:1521:your_SID", "your_login", "your_password"); } catch(SQLException sqle){ System.out.println("ERROR: Bad password specified!"); } // try
After all these actions CallableStatement works fine...
--
Sincerely yours,
Krainov, Max Jury (846-2) 349760, (846-2) 702302 Program Analyst Oracle & Java ProgrammerAlphaNet International, Inc. www.alphafx.ru, www.iproject.ru Received on Fri Mar 10 2000 - 06:54:58 CST
![]() |
![]() |