1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

How do I make reinstalled MSSQL to load plesk databases

Discussion in 'Plesk 9.x for Windows Suggestions and Feedback' started by JuanT, Jul 29, 2009.

  1. JuanT

    JuanT Guest

    How do I make reinstalled MSSQL to associate databases with plesk users

    I reinstalled SQL server 2005 on plesk 9.0 because it was not working.
    The configuration was lost.

    All the databases could be attached from backup to the server but how can I make it associate the databases with the plesk users?

    Does anyone know a command to reconfigure mssql 2005 in order to load the database information from plesk users?

    Last edited by a moderator: Jul 29, 2009
  2. Benderr

    Benderr Guest


    You can add user to mssql database with mssqlmng.exe utility like this:

    mssqlmng.exe --add-user --server="localhost" --login="sa" --password="123qwe" --database="mydomains_" --new-user-login="xoxo" --new-user-password="123qwe"

    To get all mssql databases and appropriate database users from Plesk db use this command:

    dbclient.exe --direct-sql --sql="select du.login,du.passwd, db.name from db_users du, data_bases db where du.db_id=db.id and db.type='mssql'"