aspose file tools*
The moose likes JDBC and the fly likes DSN problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "DSN problem" Watch "DSN problem" New topic
Author

DSN problem

Ransika deSilva
Ranch Hand

Joined: Feb 18, 2003
Posts: 524
Heloo,
I just wanted to know this.
I connect to MS ACCESS data bases using the normail
Class.forName(.....)
So on
The question I have is say now I can write a sql statement like this
" SELECT something FROM some Table WHERE (SELECT someotherthing FROM someothertable like that ".
Now when you create a Connection You only have DSN for one database only. Can I do this in java... if can how can I have multiple dsn to different databases
thanks


SCJP 1.4, SCMAD 1.0<br />SCWCD, SCBCD (in progress)
Ron Newman
Ranch Hand

Joined: Jun 06, 2002
Posts: 1056
You can load as many JDBC drivers as you want, and create as many Connections as you want referring to each one of them.


Ron Newman - SCJP 1.2 (100%, 7 August 2002)
Ransika deSilva
Ranch Hand

Joined: Feb 18, 2003
Posts: 524
You mean can I have like this....
Connection checkicode_con =
DriverManager.getConnection"jdbc dbc:checkicode.icode,namecode"," ","");
checkicode, icode , namecode are dsn for different table
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: DSN problem