finally, i found out that we can use sp_change_users_login to map with login name.
for my case, my database name is HHotel, user login will be 'lam' and password 'l!a2m#'
USE HHotel;
GO
EXEC sp_change_users_login 'Auto_Fix', 'lam', NULL, 'l!a2m#';
GO
It's fixed after run above script.
For more example: http://msdn.microsoft.com/en-us/library/ms174378.aspx
4 comments:
Your sample helped me. Thanks.
That's some righteous code there! Thanks, it helped me.
I would like to exchange links with your site dotnetfish.blogspot.com
Is this possible?
great post, just the kind of information I was looking for
Post a Comment