June 6, 2012

sp_MSupdaterecgen (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_MSupdaterecgen(uniqueidentifier @altrepid
, uniqueidentifier @altrecguid
, bigint @altrecgen)


 --  updates info about received generations, or inserts a corresponding row  
create procedure sys.sp_MSupdaterecgen
@altrepid uniqueidentifier,
@altrecguid uniqueidentifier,
@altrecgen bigint

-- Security check
declare @retcode int
exec @retcode = sys.sp_MSrepl_PAL_rolecheck
if (@retcode <> 0) or (@@error <> 0)
return 1

update dbo.sysmergesubscriptions
set recguid = @altrecguid, recgen = @altrecgen
where subid = @altrepid and
(recgen < @altrecgen or recgen is null)

return (0)

No comments:

Post a Comment

Total Pageviews