IConstraintConflict::GetDestinationProviderOriginalChange

Gets the change metadata from the destination provider for the item that originally caused the conflict.

HRESULT GetDestinationProviderOriginalChange(
  ISyncChange ** ppOriginalChange);

Parameters

  • ppOriginalChange
    [out] Returns the change metadata from the destination provider for the item that originally caused the conflict.

Return Value

  • S_OK.

  • S_FALSE when no original change exists.

  • E_POINTER.

Remarks

The change returned by this method represents the destination item that originally caused a change to be made that, when applied, caused a constraint conflict. For example, consider a replica that uses a name field to identify its item. The source replica contains an item with ID id1 and a name field of "John". The destination replica contains an item with ID id1 and a name field of "Joe", as well as an item with ID id2 and a name field of "John". When item id1 is applied from the source replica to the destination replica, the name field of item id1 is changed to "John". This causes a constraint conflict with item id2 in the destination replica, because item id2 already has a name field of "John". In this case, the IConstraintConflict methods return the following values:

  • GetDestinationProviderConflictingChange returns id2 and name field of "John".

  • GetSourceProviderConflictingChange returns id1 and name field of "John".

  • GetDestinationProviderOriginalChange returns id1 and name field of "Joe".

See Also

Reference

IConstraintConflict Interface