| Author |
how i can create a datasource from a JDBC connection url in my java code?
|
raminaa niilian
Ranch Hand
Joined: Jul 14, 2005
Posts: 550
|
|
Hi Thank you for reading my post. i need to create a Datasource in my java code from connection url that i have. can some one give me some help about this? Thanks
|
 |
Eric C Lee
Greenhorn
Joined: Feb 22, 2007
Posts: 4
|
|
DataSources is a concept for in-container application to get a database connection via JNDI look up in the InitialContext. You can not obtain a DataSource object from a Connection. Good Luck
|
 |
raminaa niilian
Ranch Hand
Joined: Jul 14, 2005
Posts: 550
|
|
Hi thank you reply Indeed i should create a datasource to pass it to some data provider class and i can not use application server datasource mechanism. thanks.
|
 |
Jan Cumps
Bartender
Joined: Dec 20, 2006
Posts: 2343
|
|
Have a look at the Database connection pooling services library. It allows you to create a DataSource object for your database. It's the same technology as used in Tomcat. It allows you to do database pooling outside a container or apps server. You can use it in your java application. It's not difficult to use and configure. Regards, Jan [ February 23, 2007: Message edited by: Jan Cumps ]
|
OCUP UML fundamental
ITIL foundation
|
 |
 |
|
|
subject: how i can create a datasource from a JDBC connection url in my java code?
|
|
|