How to add authenticated users in the database directly

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
3/16/2019 6:56:11 AM
Gravatar
Total Posts 2

How to add authenticated users in the database directly

Hello. I managed to add a new user in the database directly by adding a record in the table mp_Users. I also added a new record in mp_UserRoles based on the new user and added the appropriate RoleGuid to have it "authenticated". I can make the user log-in; however, the user cannot see the site menus even though his role is already  "Authenticated user". The only way I can make the user see the menus is by logging in as admin, deleting the existing authentication under Manage User > Role membership, and re-assign the "Authenticated user" role using the "Add user to this role" button. The effect it has on the table mp_UserRoles is exactly the same as when I encoded it manually in the database. I guess I am missing some database tables to modify. Do you have an idea what these may be?  

 

 

 

3/19/2019 8:20:17 AM
Gravatar
Total Posts 2

Re: How to add authenticated users in the database directly

Hello again. I was able to fix the problem. It was mostly a false alarm. My bad. I didn't fill up all the required fields in the mp_Users table, particularly the GUID fields. 

So it was as simple as that, just fill up the fields in the mp_Users and mp_UserRoles tables. I was able to batch-insert 2693 user accounts in one click this way. I apologize for any confusion this may have caused.

 

You must sign in to post in the forums. This thread is closed to new posts.