Quantcast
Channel: SQL Server Replication forum
Viewing all articles
Browse latest Browse all 4054

Orphan records in MSarticles - How to remove them

$
0
0

When I run the following query:

SELECT
	msa.*
FROM [distribution].dbo.MSarticles AS MSA
	LEFT OUTER JOIN [distribution].dbo.MSpublications AS MSP
	ON msp.publication_id = msa.publication_id
WHERE msp.publication_id IS NULL

I have articles referencing publication which do not exist.  How do I remove them?

Before anyone responds "use sp_droparticle", this requires a PublicationName which does not exist.

Before anyone responds "use sp_removedbreplication", tried that and did not remove these items.

I also dropped the published database, and the objects remain.

Any other ideas?


Viewing all articles
Browse latest Browse all 4054


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>