No announcement yet.

I need your help on multiple users with their own databases

  • Filter
  • Time
  • Show
Clear All
new posts

  • I need your help on multiple users with their own databases

    Hi All,

    I have created a project that is intended to be used by multiple users and each one will have their own mySQL database.

    For argument let us say that I have three (although there will be lots more) databases data_admin (for me), data_0001 and data_0002 (for the 2 users).

    I can do a sc_connection_edit() based on their user information to provide them with their own data, but an issue has arisen when it comes to things like changing passwords.

    This is what I have done so far after adding the security module.

    In the log-in app, in the application init event, I set the connection to the admin database so that their login can be checked and verified.

    In the validate event I check the user details and if logged in Ok, I then do a sc_connection edit() to data_001 or data_0002 etc.

    This seem to be working OK, except when they might wish to change their password.

    Once into the actual operating part of the project, they are connected to their own data and that does not include any sec_users records, as they are all in the data_admin.

    Also, I though of adding a link on the log-in app to allow users to user to go straight to the change password app, but that does not work, and I can understand why.

    So, here is the main question. Can I have some apps (the security ones) specifically assigned to the admin database, so that even though they are using their own data for day to day stuff, they will always be connected to the admin functions using the admin data file?

    If not, how are people setting up security under similar situations?



  • #2
    I have just seen a post from Daveprue back in January that may well get me on the way, but I have had another surprise.

    When I do a change password, I enter the old password and enter and confirm the new password, but when I click on the OK button, I get a small list in a "message" sized window asking me to confirm the user.

    How can I avoid this window popping up. I am assuming that the the connection to the "system" as Dave calls it, is lost when you do a sc_connection_edit() to connect to the "account".

    Anyone know how to get rid of this message?