开发者

Can you select which column to sync with Sync Framework

I notice that with MS Sync, going through the wizard to create the WCF service that will do the sync, you can only choose which table to sync.

Is it possible to only sync a开发者_Python百科 few columns of the table and not the entire table? It will also create the local sdf file with the whole table structure. I only need a few columns of the table to be displayed in my mobile device.


You can achieve this by writing code. You can use the DbSyncTableDescription

DbSyncTableDescription tableDescription = SqlSyncDescriptionBuilder.GetDescriptionForTable(tableName, Collection<Columns>, server Connection)

The second parameter is the collection of Column Names you want to include in Sync.

Hope that helps


The Sync Framework is a customizable and extensible framework hence it can surly be done. But you probably have to write some code - I am not aware that the database synchronization provider included in the framework supports synchronizing only a subset of the columns.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜