Custom Membership Provider with multi databases

Discussion in 'ASP .Net Security' started by tao lin, Sep 15, 2006.

  1. tao lin

    tao lin Guest

    Hi, all

    I have tested the Sample Access Providers from Provider Toolkit and get
    some feeling how to write a Custom Membership Provider. But now in my own
    asp.net app I cannot make my Custom Membership Provider working with multi
    databases. My aps.net web site using querystring such as
    http://localhost/myapp?client=AClient or
    http://localhost/myapp?client=BClient
    to specify which database to connet. And each database have its own User and
    Role table. We don't want a cental role and membership database because each
    database map to an independant client. And in my understanding, each
    membership provider and role provider can only point to one database through
    the connectionStringName value in Web.Config.

    Is there any way I can make use of Asp.net 2 membershipProvider and
    roleProvider with multi databases?

    Cheers,

    Tao
     
    tao lin, Sep 15, 2006
    #1
    1. Advertising

  2. You can create multiple ASP.NET databi (plural for database :->) and point
    different pieces to each. Linking the bits that have to be linked can be a
    pain.

    You can also create a separate database for each app and write scripts for
    the roles (or copy the files after initial seed and save back a copy for
    newer clients). You then add tthe client specific stuff to the shell.

    --
    Gregory A. Beamer
    MVP; MCP: +I, SE, SD, DBA

    *************************************************
    Think outside of the box!
    *************************************************
    "tao lin" <> wrote in message
    news:%...
    > Hi, all
    >
    > I have tested the Sample Access Providers from Provider Toolkit and get
    > some feeling how to write a Custom Membership Provider. But now in my own
    > asp.net app I cannot make my Custom Membership Provider working with multi
    > databases. My aps.net web site using querystring such as
    > http://localhost/myapp?client=AClient or
    > http://localhost/myapp?client=BClient
    > to specify which database to connet. And each database have its own User
    > and Role table. We don't want a cental role and membership database
    > because each database map to an independant client. And in my
    > understanding, each membership provider and role provider can only point
    > to one database through the connectionStringName value in Web.Config.
    >
    > Is there any way I can make use of Asp.net 2 membershipProvider and
    > roleProvider with multi databases?
    >
    > Cheers,
    >
    > Tao
    >
     
    Cowboy \(Gregory A. Beamer\), Sep 16, 2006
    #2
    1. Advertising

  3. tao lin

    tao lin Guest

    Hi, Gregory

    Thanks for your reply.

    So in my understanding, what you mean is impossible to use one ASP.Net app
    and one membership provider to point to different databases? You know, I
    don't want to maintain multiple asp.net apps and the only difference for
    them is the web.config file :(

    Cheers,

    Tao


    "Cowboy (Gregory A. Beamer)" <> wrote in
    message news:...
    > You can create multiple ASP.NET databi (plural for database :->) and point
    > different pieces to each. Linking the bits that have to be linked can be a
    > pain.
    >
    > You can also create a separate database for each app and write scripts for
    > the roles (or copy the files after initial seed and save back a copy for
    > newer clients). You then add tthe client specific stuff to the shell.
    >
    > --
    > Gregory A. Beamer
    > MVP; MCP: +I, SE, SD, DBA
    >
    > *************************************************
    > Think outside of the box!
    > *************************************************
    > "tao lin" <> wrote in message
    > news:%...
    >> Hi, all
    >>
    >> I have tested the Sample Access Providers from Provider Toolkit and get
    >> some feeling how to write a Custom Membership Provider. But now in my own
    >> asp.net app I cannot make my Custom Membership Provider working with
    >> multi databases. My aps.net web site using querystring such as
    >> http://localhost/myapp?client=AClient or
    >> http://localhost/myapp?client=BClient
    >> to specify which database to connet. And each database have its own User
    >> and Role table. We don't want a cental role and membership database
    >> because each database map to an independant client. And in my
    >> understanding, each membership provider and role provider can only point
    >> to one database through the connectionStringName value in Web.Config.
    >>
    >> Is there any way I can make use of Asp.net 2 membershipProvider and
    >> roleProvider with multi databases?
    >>
    >> Cheers,
    >>
    >> Tao
    >>

    >
    >
     
    tao lin, Sep 17, 2006
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Ken North
    Replies:
    0
    Views:
    609
    Ken North
    Jul 14, 2005
  2. sloan
    Replies:
    5
    Views:
    1,516
    sloan
    Jun 4, 2006
  3. Replies:
    0
    Views:
    751
  4. sloan
    Replies:
    1
    Views:
    515
    Chad Scharf
    Jul 3, 2007
  5. Brett Ossman

    Custom Membership Provider - Custom Error Messages

    Brett Ossman, Mar 11, 2009, in forum: ASP .Net Security
    Replies:
    0
    Views:
    793
    Brett Ossman
    Mar 11, 2009
Loading...

Share This Page