Multiples DB

Posts   
 
    
bemidio
User
Posts: 14
Joined: 19-Dec-2006
# Posted on: 19-Dec-2006 20:35:45   

I need to connect to 2 distincts databases. I need to insert 2 distincts keys in Web.config. Is this possible?

Regards,

Bemidio

bclubb
User
Posts: 934
Joined: 12-Feb-2004
# Posted on: 20-Dec-2006 01:18:29   

We'll need more information to be helpful. Are they exactly the same schema? Will you be using Adapter or Self Servicing. What are the database types?

If you are using Adapter and they are the same schemas then you will most likely just need one Database Generic Project and two Database Specific Projects. You can set them to use two different connectionstring keys so that you are able to have both defined in the same config file.

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39927
Joined: 17-Aug-2003
# Posted on: 20-Dec-2006 11:38:54   

You need to create two projects with llblgen pro. In the project properties in the llblgen pro designer you can define the key under which the connection string is expected. By default this is 'Main.ConnectionString'. You could opt for changing this in project A to 'DB1.ConnectionString' and in project B to 'DB2.ConnectionString'. You can then add them both to the web.config.

Frans Bouma | Lead developer LLBLGen Pro