none
Do I need another scope for every filter with a different value? RRS feed

  • Question

  • I have a master database with a bunch of data in tables in it. I have a client application that will be deployed at multiple sites, each application should sync only data from the master database that matches a set of filters where the value in the "where" clause is different for each client.

    I have a prototype that works for a single instance of the client application, but I wonder if the procedures/types/triggers generated when I provision the scope on the server will have the ID the client application used to initialize it hardcoded into the filters. In other words, do I need another scope for every client?

    Wednesday, February 26, 2014 7:21 PM

Answers

  • the filter is only applied on the select_changes sp, for every additional scope you add, you will need a separate select_changes sp and the filter value is hardcoded in the sp itself..

    to avoid that, you can create a scope template, then create the client scopes based on this template. they will all share the same select_changes sp and the filter values for each scope will be supplied from a separate table.

    have a look at this post to understand what gets generated during provisioning: Sync Framework Provisioning

    Wednesday, February 26, 2014 11:31 PM
    Moderator