Custom Fields Asp.netMembership?
Hi
The asp.net membership stuff is confusing me. I am using mssql as my provider model. However I need to add some custom fields and I am sure if it is ok to just to add them to the aspnet_user table or if I should be putting them somewhere else.
The stuff that confuses me is when I look for tutorials they talk about custom providers for non mssql database. I always considered if you merge the asp.net database that gets generated with a database you have would be a custom provider.
So I am not really sure what I am searching for.
So that is my first problem where can I stick stuff can I just tag on the 2 columns to the aspnet_users table or will that just screw something up?
The next thing I need is to extend the ValidateUser method. I want to check another field untop of "UserName" and "Password" So I am not sure how to extend it. I also want to keept he oringal ValidateUser since I am also using it to validate another type of user on my stie that does not use this other field.
Finally the last problem I have is say you have this
Prefix: ABC
UserName: Bob
Password: 1234567
Prefix: HHH
UserName: Bob
Password: 1234567
UserName: Bob
Password: 1234567
The database should treat these as all unquie names. Right now I noticed the default stuff in asp.net membership generates a error message if somone chooses the same name. I still want this but I want to have it so if somone puts a prefix that is not used then they can use the same username since it will be treated as 2 different users.
I know I could probably combine the Prefix + UserName into the UserName field and that probably work but I rather have it as 2 seperate fields in my database. Hence why I want to have a ValidateUser that would have this
ValidateUser(string UserName, string Password)
ValidateUser(string UserName,string Password, string Prefix){.....}
Thanks
|