how to approach unique user views

  • Thread starter Thread starter Neil Chambers
  • Start date Start date
N

Neil Chambers

I currently have 2 databases with one website per DB. The databases are
simple collections of views and some tables holding keys for the views -
these DBs are exact copies of eachother, other than the item values needed
to generate different views. The two websites are also identical but simply
require different ConnectionString items to point to the relevant database.

I am happy keeping the separate databases as some of the views, whilst
returning the same columns, may often require a bit of tweaking to satisfy
customer needs.

What I plan on doing is consolidating the web interfaces. It seems that all
I really need to do is assign the appropriate ConnectionString based on the
user logging in. Currently the pages hold the connectionstring info with the
SqlDataSource control:

<asp:SqlDataSource ID="mySqlDataSource" runat="server"
ConnectionString="<%$ ConnectionStrings:ConnectionString1 %>"
SelectCommand="SELECT * FROM [view1]">
</asp:SqlDataSource>

Q1. would it be possible to store the connectionstring id in a session
variable and have that used at runtime such that ConnectionString points to
a user defined variable?

Q2. what other approaches would be feasible (I'm guessing this nut has been
cracked once or twice before)?

Thanks,
n
 
oookay. so I think I am barking up the wrong tree. Membership, Roles &
Profiles seems to be what I am looking for.

Cheers,
n
 
Back
Top