karahana Posted October 26, 2005 Posted October 26, 2005 Hi there! i have a little problem... The membership class: where should i store a user's first name and last name? i thought of storing it in the user profile, but there is a problem: lets say the admin wants to see all the users in his site in a gridview, and to see the property "IsUserLocked" (aspnet_users table), together with the user's first name (which is stored in the aspnet_profile table). its not the same table... and with the structure of aspnet_profile u cant do a "SELECT" statement.... what can i do then? thank you for your help. Quote
betrl8thanever Posted October 29, 2005 Posted October 29, 2005 I'm not 100% sure I understand what your asking, but I'll give it a shot. If you have user information stored in two, or more different tables, then you can perform a query on the database that joins the information together and displays it as one record. Barring you have a common indentifier in each table that will link the two together. Using your example.... select t1.UserId, t1.Permission t2.IsUserLocked from aspnet_profile t1, aspnet_users t2 where (t1.UserId = t2.UserId) Quote "In the immortal words of Socrates, who said "' I drank what?!'"
karahana Posted October 29, 2005 Author Posted October 29, 2005 Unfortunately Unfortunately, aspnet_profile isn't built that way. its built with a string column of XML data and another binary column that both hold the entire propreties for a single user... in one row identified by UserId, u cant seperate those properties ( for example UserFirstName) by an ordinary SELECT statement (OR IS THERE A WAY?) Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.