The main issue is suppose i have two databases and when
user wants data for last 10 years data,it has to connect to
one database and if user wants data for the past 1 year,it
has to connect to the other database.like that .can i
create two data sources in one properties file.is it
possilbe.if so provide me the explaination.Thanks in
advance.

Answer Posted / vamshi krishna

from .net technology point of view, u can use multipls
connectionstrings to connect to the database.you can define
that in web.config file under appSettings as follows....

<connectionStrings>
<clear/>
<!--Report Data base Connection String -->
<add name="ReportingConnection"
connectionString="Server=192.168.1.13;Database=Pegasus;UID=p
egasus;PWD=pegasus;Pooling=true;Max Pool
Size=300;Connection Timeout=60"/>
<!-- Data base Connection String to the
pegasus admin database -->
<add name="PegasusAdminConnection"
connectionString="Server=192.168.1.13;Database=Pegasus;UID=p
egasus;PWD=pegasus;Pooling=true;Max Pool
Size=300;Connection Timeout=60"/>
<!-- Data base Connection String to the
pegasus course database (admin database course database
role. so, same as admin db conn string)-->
<add name="PegasusDBConnection1"
connectionString="Server=192.168.1.13;Database=Pegasus;UID=p
egasus;PWD=pegasus;Pooling=true;Max Pool
Size=300;Connection Timeout=60"/>
<!-- Data base Connection String to the
pegasus course 1 database -->
<add name="PegasusDBConnection2"
connectionString="Server=192.168.1.13;Database=Pegasus;UID=p
egasus;PWD=pegasus;Pooling=true;Max Pool
Size=300;Connection Timeout=60"/>
<!-- Data base Connection String to the
pegasus course 2 database -->
<add name="PegasusDBConnection3"
connectionString="Server=192.168.1.13;Database=Pegasus;UID=p
egasus;PWD=pegasus;Pooling=true;Max Pool
Size=300;Connection Timeout=60"/>
</connectionStrings>

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the maximum depth at which the open foundation bridge can be done

3447


what advice do you have for Architectural Draughtsmanship student who wish to became architects?

3321


Is DataStage Designer, a thin client or a thick client?

3237


How to calculate stabilizer for a machine

2122


how much steel bar required for 1 sqm area

1133






difference between action and collaboration in object oriented designing and modeling

2182


What is meant by OSI model?

1552


Why do u want to join vastu vihar

1068


why you want to become artictecture

1957


Who is responsible for territory? can you please help me in getting the answer for this

1884


Structural wall & slab : Binding wire fixing is alternatively spacing is correct or wrong?. binding wire fixing is all spacing is must or not?

2159


what is the difference between R/3 Number range and CRM range?

1933


what is the rate of 4000sqft rate, with material tile plumbing all work with plinth? Pl. Send ans. Yourlifeme@indiatimes.com

2377


details about telephone wiring

1914


What is meant by fetch and execute cycle in cpu operations

1024