locked
Client Side Tracking (Disconnected Mode) RRS feed

  • Question

  • Hi All,

    I am Working on Synchronazation between client(sql server CE) and Server(Sqlserver 2005) both connected mode as well as disconnected mode.

    When The Device(WM6.0) is in Disconnected Mode user can Insert/update/delete the rows. Now i need to track the insert/update/delete rows  in .sdf file. (sqlserver ce).

    can any one help me to How to track  these rows(different tables).

    Thanks In Advance.
    • Moved by Hengzhe Li Friday, April 22, 2011 2:58 AM (From:SyncFx - Microsoft Sync Framework Database Providers [ReadOnly])
    Tuesday, June 9, 2009 1:30 PM

Answers

All replies

  • Can you provide more information for you scenario? Are you building your application on the Microsoft Sync services for ADO.net? If yes, the changes in the CE database should be tracked already.

    Thanks,
    Dong
    This posting is provided AS IS with no warranties, and confers no rights.
    Wednesday, June 10, 2009 1:04 AM
    Moderator
  • Thanks dong for response.

    I am building the application using Microsoft Sync services for ADO.net. But How to display these(insert/update/delete) details in grid?  can you please provide any example Project or any article. How we can track these details in CE?

    Thanks In Advance.

    Wednesday, June 10, 2009 5:54 AM
  • I'm not sure if I correctly understand your ask. I assume that you want to display all new changes that are introduced by the current sync, and you want to mark each row changed by Sync with insert/update/delete flag in your Grid UI control. I don't think that there is a straightforward way to get this information today because Sync Services for ADO.Net doesn't raise event for each applied change.

    One possible way for you to try is: you can get the Context.DataSet from the ApplyingChange event, this dataset contains all incoming sync changes that will be applied on the local store. Combining with the items that are not successfully applied in the ChangeFailed event. you can get the final applied list with the insert/update/delete info.

    If my first guess is not right, the second guess is that you want to display each local DML in the offline CE store after the previous sync. Sync Service cannot help you for this. You need to start a new sync and let this CE store to be the source, Context.DataSet in the ChangeSelected event will contain such info.

    Thanks,
    Dong


    This posting is provided AS IS with no warranties, and confers no rights.
    Wednesday, June 10, 2009 6:44 AM
    Moderator
  • Thanks Dong,

    But the event "ApplyingChange " will fire  only when  we synchronize .


    Thanks
    Lakshmi Narayana
    Friday, June 12, 2009 2:29 PM
  • That's true. For CE store, we have some internal change tracking info but cannot expose it to a sync application if a sync is not happening.

    Thanks,
    Dong


    This posting is provided AS IS with no warranties, and confers no rights.
    Friday, June 12, 2009 7:19 PM
    Moderator
  • Hi Dong Thanks For response.

    I found one article in this forums.

    http://social.microsoft.com/Forums/en-US/uklaunch2007ado.net/thread/c72a7626-1b8a-42fa-9fc9-610fc137eabc

    In this Article they provided one query

    But that query is giving Error.

    Field "LCSN" is not found " so can you please help me on this.

    Thanks
    Lakshmi Narayana
    Monday, June 15, 2009 9:18 AM
  • Lakshmi Narayana found the answer himself: http://social.msdn.microsoft.com/Forums/en-US/uklaunch2007ado.net/thread/68a2c86c-e0f9-428e-a0a9-38c1cb7b6f36


    This posting is provided AS IS with no warranties, and confers no rights.
    Monday, June 15, 2009 9:41 PM
    Moderator