May 25, 2012

sp_MSrepl_IsUserInAnyPAL (Transact-SQL MetaData) Definition

Please note: that the following source code is provided and copyrighted by Microsoft and is for educational purpose only.
The meta data is from an SQL 2012 Server.

I have posted alot more, find the whole list here.

Goto Definition or MetaData

Definition:

sys.sp_MSrepl_IsUserInAnyPAL(bit @raise_error)

MetaData:

 CREATE PROCEDURE sys.sp_MSrepl_IsUserInAnyPAL  
@raise_error bit = 1
AS
-- sysadmin or db_owner have access
if is_member('db_owner') = 1
return 0

if exists (select name from sys.objects where name='sysmergepublications') and
exists (select name from dbo.sysmergepublications where ({fn ISPALUSER(pubid)} = 1))
begin
return 0
end
else
begin
if @raise_error = 1
RAISERROR (14126, 11, -1)
return (1)
end

No comments:

Post a Comment

Total Pageviews