June 8, 2012

sp_scriptsubconflicttable (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_scriptsubconflicttable(nvarchar @publication
, nvarchar @article
, bit @alter
, bit @usesqlclr)

MetaData:

 create procedure sys.sp_scriptsubconflicttable (  
@publication sysname
,@article sysname
,@alter bit = 0 -- if 1 script alter, otherwise script create
,@usesqlclr bit = 1
)
as
begin
declare @retcode int

--
-- Security Check.
--
exec @retcode = sys.sp_MSreplcheck_publish
if (@@error != 0 or @retcode != 0)
return (1)

--
-- Parameter Check: @publication.
-- The @publication cannot be NULL and must conform to the rules
-- for identifiers.
--
if (@publication IS NULL)
begin
raiserror (14043, 16, 2, '@publication', 'sp_scriptsubconflicttable')
return (1)
end
exec @retcode = sys.sp_validname @publication
if (@retcode != 0)
return (1)

--
-- Parameter Check: @article.
-- The @article cannot be NULL and must conform to the rules
-- for identifiers.
--
exec @retcode = sys.sp_MSreplcheck_name @article, '@article', 'sp_scriptsubconflicttable'
if (@@error != 0 or @retcode != 0)
return (1)

if LOWER(@article) = 'all'
begin
raiserror (14032, 16, 2, '@article')
return (1)
end

--
-- now call the SP to generate the script
--
exec @retcode = sys.sp_MSmakeconflicttable @article = @article, @publication = @publication, @creation_mode = 1, @is_debug = 0, @alter = @alter, @usesqlclr = @usesqlclr
return @retcode
end

No comments:

Post a Comment

Total Pageviews