Re: Unexpected problem with synchronisation



"Dave G @ K2" <DaveGriffiths70@xxxxxxxxx> wrote in
news:1148393708.623609.39690@xxxxxxxxxxxxxxxxxxxxxxxxxxxx:

David

Firstly, the reason I used an unbound form in this particular
application was - well I can't actually remember now. But I do
remember that I went through the pain of converting from bound to
unbound, and I was glad I did because it solved all my problems,
whatever they were at the time. Generally I feel that I am in
better control with unbound forms despite the extra effort.

I think my example of null was a red herring. Please ignore.
Here's the problem again as reported by the client:

1) Synchronise replicas

Are you talking about replicated Jet databases?

2) In the replica (ie on a laptop) make a change to a field in
the carer table. e.g. change the surname of a carer.
3) Close the record.
4) On the base station open up that carer record and close it
without making any changes.
5) Synchronise replicas

The data on both the replica and the base station will now be
without the change made to the replica. It seems that the opening
and closing of the record without changes wins the synchronisation
conflict with the previously changed record.

You're now talking about something else entirely.

The resolution of replication conflicts follows strict rules. In Jet
3.5, it was "least decisive user wins" (i.e., the record with the
most changes in it), while in Jet 4, it's substantially more complex
(because conflicts are resolved at field level, rather than at
record level), and involves replica priority. There's an easily
found Knowledge Base article that explains how replica priorities
are set. Replicas with higher priorities win. The design master has
higher priority than all replicas, and any replica made direct from
the design master will have the same priority. Replicas made from a
replica of the DM will have a lower priority (and so forth).

You can also create custom conflict resolution rules that treat the
records according to your own rules.

Now, I'm assuming that this problem occurs because when I close
the unbound form I save all fields back to the table. If I'm right
so far, then I'm also assuming that the way to solve it is to only
save fields that have changed. So that's what I'm looking to do,
but I'm trying to find a neat way of doing it rather than some
horribly long winded way.

Well, never save a record that hasn't changed.

I always populate an unbound form from a recordset. I then retain
that recordset and compare the values at SAVE time to that original
recordset (make it a snapshot so it won't refresh when other users
edit the data).

It's important in replicated databases to not force saves when no
data has actually changed because, as you seem to have discovered,
this can screw up conflict resolution.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
.



Relevant Pages

  • Re: Replication & Synchronizing
    ... IF you had created the replica, then edited the replica, THEN ... But you wouldn't necessary have a conflict reported for resolution ... the one with the higher priority would win the conflict. ... No single replica can synch with two replicas simultaneously. ...
    (microsoft.public.access.replication)
  • Re: Unexpected problem with synchronisation
    ... the reason I used an unbound form in this particular ... Synchronise replicas ... e.g. change the surname of a carer. ... The data on both the replica and the base station will now be without ...
    (comp.databases.ms-access)
  • RE: How to handle conflicts?
    ... Because more than one replica has updated data in the same record (in the ... - How can I avoid data conflicts? ... Creating smarter synchronization schedules. ... Replicas are assigned a priority, a real number between 0 and 100, ...
    (microsoft.public.access.replication)
  • Re: synchronizing replicas
    ... Design Master and the replica I receive the error message 'MS Jet database ... Any suggestions on how to resolve this error? ... 'Update/update conflict. ...
    (microsoft.public.access.gettingstarted)
  • Re: Replication gone crazy
    ... 'Microsoft Replication Conflict Viewer' gets stuck for 15-20 ... This updated record was deleted at another replica. ... The log file most likely has two entries because you have synched ...
    (comp.databases.ms-access)