The current template set uses DAO objects internally, which means, the DAO object is called from inside the entity classes/collection classes. This can be limiting. The template set that is released in November will solve this: it will have separate DAO objects which accept a connection string among other data, like an entity to save or fill, or f.e. a datareader object to use to fill an entity collection. But this doesn't help you at the moment. So I have a question:
Are the databases identical (A) or does your project reference more than 1 database (B)?
In the case of (A), for example when the user can select the database he connects to from a list in the gui, there is a problem, and I have to look into that how to solve that quickly for you.
In the case of (B), you create a project for each database you reference. In the project properties, you can specify the name of the tag where the connection string is stored in. Compile each project separately and reference them in your code as normal assemblies. Add each connection string tag found in the generated app.config files to the app.config file you're working with. Each assembly will now load its own connection string and connect to the correct database.
When you run into conflicts when types are defined multiple times, alias the namespaces in your codefile using 'using' (C#) or 'Imports' (VB.NET)
So I guess I have to change these methods. But since I don't have a context when calling this methods, how do I decide for which database the connection string should be returned?
This is the problem with the current templates. The code they generate works ok, but when other scenarios are required, it can be limiting, because there is no way you can pass down a connection string when saving an entity for example (which would be odd anyway, because you're working with entities, not data-related material).
I hope you're working with multiple databases which are not the same so you can solve it yourself.