views:

107

answers:

2

I have mobile application, so i dont want to send/receive whole changes in tables..Just some data, that meets some filter terms. Is it possible to achieve with SF; if it is, please provide some resources to read about it, because i found almost nothing.
Thank You.

+2  A: 

It's definitely possible with SQL Server Replication Services (SSRS). You can select which tables, fields, and even apply filters to the publication. I'm not familiar with Sync Framework but SSRS subscriptions appear in the Sync Center, so my assumption is that Sync Framework uses SSRS.

Jamie Ide
Thank You for the answer, but can you provide some documentation on HOW to do that(sorry, but this is my first time hearing about SSRS)? I'd searched for it myself, but its urgent and if you know where the documentation is, please help once again. thank you
nihi_l_ist
SSRS is a fairly complex technology. Actually any replication is, and I'd be very nervous about implementing it with urgency. This link is for SQL 2000 but has screenshots: http://www.mssqlcity.com/Articles/Replic/SetupSR/SetupSR.htm. There's a wealth of info in SQL Server BOL: http://technet.microsoft.com/en-us/library/ms151198.aspx
Jamie Ide
Thank you for responses!..hmm..may be THIS: http://msdn.microsoft.com/en-gb/library/bb726003.aspx is the solution i need?..
nihi_l_ist
That looks right to me. Hopefully I pointed you in the right direction even if I didn't answer the question.
Jamie Ide
+1  A: 

Yes its possible. For example you might only want to sync the records relating to a specific store, rather than all the changes in the store table.

You do this by adding a parameter to the SyncParameters collection. e.g.

m_SyncAgent.Configuration.SyncParameters.Add("@ParamName", paramValue)

This will pass the parameter data to the serverside of the Sync process, which you can then use to sync only the data you want to include.

JohnnyJP
but if understood you right-i should change the queries in cache.designer file too(to use the parameter). but after "refreshing" sync dependancies-ill have to manually add these parameters back, because the file will be regenerated by VS...am i right? thank you for the help!
nihi_l_ist
nihi_I_ist, thats right. I tend to use the sync designer to come up with the initial cache designer, then modify by hand, using a partial class to override the one proc that I need to change to include the parameter.
JohnnyJP
By the way did the thing ;) Managed to pass the parameters from cs(not designer file) so i had no need to add them by hand every time the designer was rebuilt by the IDE
nihi_l_ist
Cool, glad you managed to resolve your issue
JohnnyJP