| Author |
Loading Driver automatically
|
faisal hameed
Ranch Hand
Joined: Jan 19, 2009
Posts: 48
|
|
I am using sql DataBase.I create connection using the following code.How can i load driver automatically without makin DSN in DataSources(ODBC).And how can i use my table in my Project Folder instead of in Sql folder, where i install sql server.
|
Regards, M Faisal Hameed
PUCIT, Pakistan
|
 |
Ashwin Bangar
Greenhorn
Joined: Jul 02, 2009
Posts: 10
|
|
Hello Faisal,
You are using Type-1 Driver for JDBC connection, instead of that try to use thin driver i.e. Type-3 driver. in that you have to specify the "vendor related url".
One more thing is that you are using sql, what does that mean, MS-Sql server or MySql or Oracle or something else...
so depending on the Sql you are using you have to specify the url in
String conURL = "jdbc:Odbc:dBServlet";
|
SCJP 5
Now Moving for SCWCD and then for OCA & OCP
|
 |
 |
|
|
subject: Loading Driver automatically
|
|
|