mapping orphan user to logins of current server | SQL Server Performance Forums

SQL Server Performance Forum – Threads Archive

mapping orphan user to logins of current server

I have attached several databases manually.I had done this manually because I dont know about the server where it originally existed.ofcourse these dbs had been detached from some server , but now I have no information.These dbs have been given to me by mgmt.and they dont have any info abt the original server
Each and every db has a user.Now after attaching these mdf and ldf, i execute a script to display the orphan users in the current server with their resp db.I see all the dbs which I had attached are listed.I dont have any information of the server where these dbs originially existed.So how can i make these users mapped to the current login in new server so that I can work with these dbs.
What are the other things which need to be trouble shooted to make these dbs fully functional,on new server.
Use the sp_fixuser script in this post to remap the orphan logins. Note that the logins has to be created on the new server first: