ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ashish Kulkarni" <ashish.kulkarn...@gmail.com>
Subject how to use ibatis to get data from multiple databases
Date Tue, 13 Feb 2007 20:03:39 GMT
Hi
I have a web application where i am using ibatis, i have a situation where i
want to select the database from where i want to get data.

In this application user will login and select he wants to use development
1, or development 2 or test 1 from a drop down

So if the user selects development1 i want to use database for development1
and so on.

But in ibatis i can define only one database in sqlMapConfig.

Also i can define multiple sqlMapConfig files (multiple xml files) one for
each database, but then in my servlets i will have to keep track of all the
sqlMapConfig

I want to be able to add these database at runtime.

Any ideas how we can do this

Ashish

Mime
View raw message