Does anyone have a script that will dump/load the database but keep user permissions login-ud's etc when we dump and load or could someone let me know which steps to take in order to write this script.
I do not know which load you are talking about.. if u r going to dump and load the database from the same server, with out building the master you need not know about the login/user details. the load will take care of everything.. anyway the login information will be stored only in the master db.
Basically we load from production to a development server and the logins from prod etc are not contained so guess I BCP out master..syslogins and bcp them into the development server would this be correct but if they exist already will their UID and SUID's not match?
Then login as 'sa' and drop users in the user database and recreate the user for the user database ... (do not drop login). then give proper grant permission for the object or assign to the proper group to the user..
I hope that u have only login problems but not the user permission problem.
1) bcp out the syslogins from the production database.
2)Login into the Development server as 'sa' and delete all logins from syslogins whose suid > 3.
3)Delete first three rows in the bcp out file,that contains login name are
4)bcp in the out file.