phpgroupware-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Phpgroupware-developers] addbook conduit logic


From: Jason Wies
Subject: Re: [Phpgroupware-developers] addbook conduit logic
Date: Sat, 20 Jul 2002 22:09:39 -0400
User-agent: Mutt/1.2.5i

On Fri, Jul 19, 2002 at 02:22:24PM -0400, Brian Johnson wrote:
> But how do I prevent an org info change from
> individual one from being reset by the org info from individual two?  So I
> add another table that fits between palm_addbook (call it palm_addbook2)
> that contains a sequential record number (id), a field to point to the phpgw
> addbook organization record (phpgw_org_rec_id), and field with a flag that
> can be triggered when the org info is changed during a sync so that no other
> record changes that organization's info again during the same sync (it would
> be reset at the end of the sync).

You should also store the name of the field that changed, ie. address or phone, 
so that changes to two different fields of an organization's info on two 
different individuals on the Palm could both by synced.  You only run into 
trouble when, say, the address field for the organization is changed in two 
individual records.  Changing the address in one and the phone number in 
another shouldn't cause a problem.

> One potential problem with this is that
> an interupted sync would prevent the organization's info from being changed
> during the next sync and any changes not transferred before th interuption
> would be lost

It might be worth storing the MD5 sum of the field's value along with the field 
name in the palm_addbook2 table.  This way you can recover from an interrupted 
sync by comparing the previously stored value with the value coming from the 
Palm now (although maybe just comparing date entered would be enough?).

Jason Wies aka Zone



reply via email to

[Prev in Thread] Current Thread [Next in Thread]