create procedure sys.sp_MSdrop_article_conflict_table
@pubid uniqueidentifier,
@artid uniqueidentifier
as
set nocount on
declare @owner sysname
declare @tablename sysname
declare @qualified_tablename nvarchar(517)
select @tablename= conflict_table
from dbo.sysmergearticles
where pubid=@pubid and artid=@artid
if @tablename is null return 0
select @owner= schema_name(schema_id) from sys.objects where name=@tablename and type = 'U'
select @qualified_tablename= quotename(@owner) + '.' + quotename(@tablename)
if object_id(@qualified_tablename, 'U') is not null
begin
exec ('drop table ' + @qualified_tablename)
end
if @@error<>0 return (1)
update dbo.sysmergearticles set conflict_table= NULL where pubid=@pubid and artid=@artid
return 0