|
|
attach user in SQL 2005 after restore of database
Last post 01-13-2008, 12:54 PM by pskobel. 0 replies.
-
01-13-2008, 12:54 PM |
-
pskobel
-
-
-
Joined on 01-24-2007
-
-
Posts 21
-
-
|
attach user in SQL 2005 after restore of database
IF EXISTS ( SELECT name
FROM master.sys.databases sd
WHERE name = N'LabelStationLog'
AND SUSER_SNAME(sd.owner_sid) = SUSER_SNAME() )
EXEC [LabelStationLog].dbo.sp_changedbowner @loginame=N'UserName',
@map =false
GO
|
|
|
|