Hi friends ,
Myself dilip while learning java, JDBC:ODBC bridge to connect java
application with Ms-Access we easily do using
DriverManager,Connection,Statement,PreparedStatement,ResultSet,
ResultSetMetaData.
But when i try to connect java program to Oracle it's gives a number
of errors.please ,If anyone has appropriate solution to this provide
me.
Thanks .
Dilip Kumar
http://www.intelcs.com/IT-Companies/
DRS.Usenet@sengsational.com - 31 Aug 2007 19:52 GMT
public OracleConnection connect() throws Exception {
String connectString =
"jdbc:oracle:thin:@some.server.name:someportnumber:somedatabasename";
OracleDriver driver = new OracleDriver();
driver = null;
Class.forName ("oracle.jdbc.driver.OracleDriver");
con = (OracleConnection)
DriverManager.getConnection(connectString,userid, password);
con.setAutoCommit(false);
return con;
}
You need to find a copy of classes12.jar.
--Dale--
Lew - 31 Aug 2007 22:04 GMT
> public OracleConnection connect() throws Exception {
> String connectString =
[quoted text clipped - 9 lines]
>
> You need to find a copy of classes12.jar.
Make that ojdbc14.jar at a minimum. ojdbc5.jar and ojdbc6.jar are also available.
<http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/htdocs/jdbc_111060.html>
It's not good to recommend obsolete tech.

Signature
Lew
DRS.Usenet@sengsational.com - 28 Sep 2007 17:02 GMT
> DRS.Use...@sengsational.com wrote:
> > You need to find a copy of classes12.jar.
[quoted text clipped - 4 lines]
>
> It's not good to recommend obsolete tech.
But it's okay as long as folks like you are around to keep me honest!
Thanks, by the way, since I was having a memory issue with TTCItem and
I'll bet more current Oracle code will have fixed that bug... on my
way to your link right now to see if that's the case.
--Dale--
Roedy Green - 01 Sep 2007 14:04 GMT
>But when i try to connect java program to Oracle it's gives a number
>of errors.please ,If anyone has appropriate solution to this provide
>me.
see http://mindprod.com/jgloss/jdbc.html#CONNECTING

Signature
Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com