May 29, 2012

sp_MSsetreplicaschemaversion (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


sys.sp_MSsetreplicaschemaversion(uniqueidentifier @subid
, int @schemaversion
, uniqueidentifier @schemaguid)


 create procedure sys.sp_MSsetreplicaschemaversion(  
@subid uniqueidentifier,
@schemaversion int,
@schemaguid uniqueidentifier
) AS
set nocount on
-- Check to see if current publication has permission
declare @retcode int

exec @retcode = sys.sp_MSrepl_PAL_rolecheck @repid = @subid
if (@retcode <> 0) or (@@error <> 0)
return 1

update dbo.sysmergesubscriptions set schemaversion = @schemaversion, schemaguid = @schemaguid
where subid = @subid

if @@error <> 0
return (1)

return (0)

No comments:

Post a Comment

Total Pageviews