Enterprise Library - Dynamic Database Factory
How do I use the Data Access Block with connection information that is not known until runtime?
Ron Jacobs published the Dynamic Database Factory which is a part of the EntLib Extension project at got dot net, The project demonstrates how you can create configuration context which allows you to use the data access block without having meta-configuration defined in your app.config file.
The full answer can be found over here
And the EntLib Ext. Project can be found over here