Solved

Removal of replicas from MsysReplicas table

Posted on 1997-10-09
5
959 Views
Last Modified: 2006-11-17
If you corrupt a replica, you will probably need to recreate it from
scratch.  This is not so much of a problem, but what is a pain in the xxx
is that the Replication Manager thinks it is still there the Map is showing
the replica as per normal.
So,  How do you delete this entry?
I understand that this is actually an entry in the MsysReplicas but I have
no idea as to how to remove it from there.  Some entries can be removed by attempting to synchronise with them using the Access Menu and selecting an entry from the list, but others do not make themself available on the list and consequently do not lend themselves to be removed from the list.
I need to know of a method to remove any Replica i choose to from the MsysReplicas table.
0
Comment
Question by:Carmy
  • 2
  • 2
5 Comments
 
LVL 4

Expert Comment

by:ozphil
ID: 1956991
Carmy, see if this method from Microsoft works.
I think the coding approach will do the trick if your cant see the replica name in the list.

This method was for Access95, but should work for 97.
You can create a custom procedure that tries to synchronize with the deleted replica using the Synchronize method. If the database is not found, its name is removed from the synchronization list. Run the following procedure in each database in the replica set where you want to remove a deleted replica name from the synchronization list.

   Sub RemoveDeletedReplica()
      Dim strDelReplica as String
      On Error Resume Next
      strDelReplica = InputBox _
         ("Enter the full path and name of deleted replica")
      CurrentDb.Synchronize strDelReplica
   End Sub

Type the path and file name of the deleted replica in the input box. After the procedure runs, you can point to Replication on the Tools menu, and then click Synchronize Now. Note that the deleted replica no longer appears in the Synchronize With box.

NOTE: This method does not work if you create a replica, delete it, create another replica with the same path and file name, and then delete that replica again.
0
 
LVL 1

Author Comment

by:Carmy
ID: 1956992
ozphil!
Thanks for your solution and good effort.  However, this method unfortunately does not remove any of these ghost replicas the user sees on the Replication Manager. These replicas are a leftover from corrupted replicas that have been replaced by now (See Note in your answer.)
I would like to get a hold on a method to simply REMOVE records on the MsysReplicas table - Yes, I know it is System table etc. but there must be a method to clean it or at least set some of the fields in it.
0
 
LVL 4

Expert Comment

by:ozphil
ID: 1956993
Great Note eh. Tells you 'this method' doesnt work when.... Well MS, tell us what DOES work.
0
 
LVL 1

Author Comment

by:Carmy
ID: 1956994
Adjusted points to 200
0
 

Accepted Solution

by:
hjack earned 200 total points
ID: 1956995
I have been on the phone to MS for a week about replicas and just having read writes throught the Jet-Engine to VB...

this code gives you rights to the system tables..
    Set DBEngine = Nothing
    DBEngine.SystemDB = "c:\windows\system\system.mdw"
you then set your database object normally etc...
I have never tried to alter the contents of system tables using this, I use it for read purposes only... but MS told me that you could --- they went on and on about how they wouldn't support me if I altered the contents of a system table...

hope it helps...I'd enter this as a comment, but on the off chance it works, what the hell...

0

Featured Post

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Explanation of Access VBA code 2 36
data analyst 3 49
Getting the Error "User-defined type not defined" in MS Access 2013 16 44
tabctrl with page click event 9 0
This article is a continuation or rather an extension from Cascading Combos (http://www.experts-exchange.com/A_5949.html) and builds on examples developed in detail there. It should be understandable alone, but I recommend reading the previous artic…
Regardless of which version on MS Access you are using, one of the harder data-entry forms to create is one where most data from previous entries needs to be appended to new records, especially when there are numerous fields and records involved.  W…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now