locked
AcceptChanges() overload to accept changes for specific rows on client RRS feed

  • Question

  • Hi all

    Are there plans to provide an SqlCeClientSyncProvider.AcceptChanges overload that accepts a list of row primary keys to specify the rows?

    If not, how could this be achieved outside Synchronization Services? Would the following sql statement work for the client db to accept custom inserts of selected rows?

    Code Snippet

    Update mytable set __sysInsertTxtBsn = null where mytable.id in (1,2,3,..)


    Thanks!
    • Moved by Hengzhe Li Friday, April 22, 2011 5:20 AM (From:SyncFx - Microsoft Sync Framework Database Providers [ReadOnly])
    Monday, December 22, 2008 10:34 AM

Answers

  • There is a way to get this done, if you have a list of PK for the rows you care on the client side.

    Subscribe to the client provider event ApplyingChanges(). When changes were enumerated from the server and the dataset arrives on the client machine, the sync application can actually retrieve those data through the dataset object before they got applied.  If you like, you can modify the dataset in this event (with the list of PKs).  However, this can also expose a chance for data loss.

    Thanks.


    Leo Zhou ------ This posting is provided "AS IS" with no warranties, and confers no rights.
    Thursday, March 19, 2009 12:27 AM
    Answerer

All replies

  • just bumping this post as this question is of interest
    Tuesday, March 17, 2009 9:34 AM
  • There is a way to get this done, if you have a list of PK for the rows you care on the client side.

    Subscribe to the client provider event ApplyingChanges(). When changes were enumerated from the server and the dataset arrives on the client machine, the sync application can actually retrieve those data through the dataset object before they got applied.  If you like, you can modify the dataset in this event (with the list of PKs).  However, this can also expose a chance for data loss.

    Thanks.


    Leo Zhou ------ This posting is provided "AS IS" with no warranties, and confers no rights.
    Thursday, March 19, 2009 12:27 AM
    Answerer