none
SqlCeClientSyncProvider is for SQL Server Compact, then what about SqlExpress?

    Question

  • Hi,

    I'm following this walk-through http://msdn.microsoft.com/en-us/library/bb726003.aspx.
    My case is almost the same. Need to filter with parameters at sync time (runtime).
    Except that my client and my server are SqlExpress and SqlServer.

    Neither of them are SqlServer Compact.

    I got stuck at providing a SyncProvider for Client, in the tutorial it is using 

        public class SampleClientSyncProvider : SqlCeClientSyncProvider
        {
    
            public SampleClientSyncProvider()
            {
                //Specify a connection string for the sample client database.
                Utility util = new Utility();
                this.ConnectionString = Utility.ConnStr_SqlCeClientSync;
             }
        }
    

    Is there alternative for SqlCeClientSyncProvider  if i'm using SqlExpress?

    Thanks

    Monday, September 23, 2013 5:59 PM

Answers

  • only SQL CE is supported in the older offline provider. 

    if you want to use SQL Express on the client, you will hvae to use the newer SqlSyncProvicer/SqlCeSyncProvider/SyncOrchestrator combo

    • Marked as answer by ZuriJAckshoT Tuesday, September 24, 2013 6:09 AM
    Tuesday, September 24, 2013 1:24 AM
    Moderator
  • yes, dynamic filtering is not supported.

    if you want, you can intercept the changes in the ChangesSelected event and do your custom filtering there by removing rows from the change datatable not satisfying your condition

    • Marked as answer by ZuriJAckshoT Tuesday, September 24, 2013 6:09 AM
    Tuesday, September 24, 2013 5:57 AM
    Moderator

All replies

  • only SQL CE is supported in the older offline provider. 

    if you want to use SQL Express on the client, you will hvae to use the newer SqlSyncProvicer/SqlCeSyncProvider/SyncOrchestrator combo

    • Marked as answer by ZuriJAckshoT Tuesday, September 24, 2013 6:09 AM
    Tuesday, September 24, 2013 1:24 AM
    Moderator
  • If i understand correctly from the other post is that if i use SqlSyncProvicer/SqlCeSyncProvider/SyncOrchestrator combo,
    I have to provision with filtered scopes first before sync time and dynamic row filtering at sync time (runtime) is not possible.

    My case is as below, can I achieve this with Microsoft Sync Framework?

    // 1. Provide server connection string

    // 2. Provide client connection string

    // 3. Provide server & client table name -- here table names and the columns are the same

    // 4. Provide select statement with filter clause -- this would come from user at runtime

    // 5. Synchronize


    Tuesday, September 24, 2013 3:40 AM
  • yes, dynamic filtering is not supported.

    if you want, you can intercept the changes in the ChangesSelected event and do your custom filtering there by removing rows from the change datatable not satisfying your condition

    • Marked as answer by ZuriJAckshoT Tuesday, September 24, 2013 6:09 AM
    Tuesday, September 24, 2013 5:57 AM
    Moderator
  • For dynamic filtering I run a stored procedure "spSubscribe" before the sync that appends to a "Subscription" table all the record keys for my dynamic filter (and a ClientID) ... the provisioned filters all return data based on everything the Subscription table for that client.

    For example, the root subscription table might contain EmployeeID and ClientID ... all the provisioned filters return Employee, EmployeeAddress and EmployeeHistory, etc. based on the Subscription table's records.

    Friday, October 18, 2013 3:49 PM