db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@apache.org>
Subject Re: openConnection dissapeared from BaseJDBCTestCase.java
Date Tue, 14 Nov 2006 15:18:25 GMT
Julius.Stroffek wrote:
> Daniel John Debrunner wrote:
>> I just added a utility method
>>
>> JDBCDataSource.getDataSource(String dbName)
>>
>> to obtain a connection to a different database, eg.
>>
>> ds = JDBCDataSource.getDataSource("otherdb");
>> conn = ds.getConnection();

> Would it be possible to create a test which passes some attributes to 
> JDBC connection? I have not found anything related to this.

Once you have the DataSource for the database then you can set any 
attributes or DataSource properties you need.

JDBCDataSource.getDataSource(); // default database
JDBCDataSource.getDataSource("otherdb"); // specific database


Dan.


Mime
View raw message