microsoft-sync-framework

When would you use GUIDs as primary keys? [duplicate]

不打扰是莪最后的温柔 提交于 2019-12-09 04:25:37
问题 This question already has answers here : Closed 10 years ago . Possible Duplicate: Advantages and disadvantages of GUID / UUID database keys Are there any circumstances where it is essential to use GUIDs as primary keys in a SQL Server 2005/8 DB. For example, does the use of the MS Sync Framework force this, or data replication? 回答1: You would use guids as a key if you needed multiple databases synchronising via replication. Another reason to use guids is if you wanted to create rows on some

Mocking a type with an internal constructor using Moq

僤鯓⒐⒋嵵緔 提交于 2019-12-08 15:40:54
问题 I'm trying to mock a class from the Microsoft Sync Framework. It only has an internal constructor. When I try the following: var fullEnumerationContextMock = new Mock<FullEnumerationContext>(); I get this error: System.NotSupportedException: Parent does not have a default constructor. The default constructor must be explicitly defined. This is the stack trace: System.Reflection.Emit.TypeBuilder.DefineDefaultConstructorNoLock(MethodAttributes attributes) System.Reflection.Emit.TypeBuilder

Getting started with Sync Framework and SQlite

不羁的心 提交于 2019-12-08 03:54:28
问题 I'm new to Microsoft Sync Framework and trying to synchronize an SQlite database with Sql Server, any good links ? 回答1: there's no out-of-the-box sync provider for Sqlite, so you have to write your own. or you can have a look at these links: Synchronization with SQLite on WinRT SYNCHRONIZING WINRT/SQLITE USING SYNC FRAMEWORK TOOLKIT even if you're not building a WinRT app, you can modify the code to work in an ordinary desktop mode non WinRT type of app. 来源: https://stackoverflow.com

Entire local database sync with sql azure

若如初见. 提交于 2019-12-08 01:30:10
问题 I am developing a windows application which is using local database. I want to add a function to sync all local data to the sql azure. Currently I used following code. It enabled me to sync one particular table successfully., here is "Author_Master" string sqlazureConnectionString = "XXXX"; string sqllocalConnectionString = "Server=localhost;Database=Enh_Branchwise_Master_Bookshop;Trusted_Connection=True"; using (SqlConnection serverCon = new SqlConnection(sqlazureConnectionString)) using

SyncFramework 2.1 updates & deletes do not seem to apply properly

£可爱£侵袭症+ 提交于 2019-12-07 22:45:18
问题 I'm synchronizing SQL Server 2008 with ~6 SQL Server 2008 Express clients (everything R2 I believe), using the SyncOrchestrator or specifically using http://code.msdn.microsoft.com/windowsdesktop/Database-SyncSQL-Server-e97d1208 as a base with slight modifications. To my knowledge this means all connections are peers or nodes. I have 2 scopes. One is download only and the other is upload only. The download only scope is ridden with identity columns primarily because I didn't know any better

sync framework server to server synchronization

牧云@^-^@ 提交于 2019-12-07 21:01:43
问题 I have kind of a such scenario: (source: microsoft.com) Here i need to synchronize local server database with main DB server(example: computers in office are connected to office server and they use it like a local server, so that no sync is required.BUT computers in other office work with their local server too and we need synchronization between the offices though the main DB server.). As i see i cant use SQLCompact here. Is there a provider to do the server-to-server synchronization right

Entire local database sync with sql azure

久未见 提交于 2019-12-06 13:29:34
I am developing a windows application which is using local database. I want to add a function to sync all local data to the sql azure. Currently I used following code. It enabled me to sync one particular table successfully., here is "Author_Master" string sqlazureConnectionString = "XXXX"; string sqllocalConnectionString = "Server=localhost;Database=Enh_Branchwise_Master_Bookshop;Trusted_Connection=True"; using (SqlConnection serverCon = new SqlConnection(sqlazureConnectionString)) using (SqlConnection clientCon = new SqlConnection(sqllocalConnectionString)) { var provider1 = new

Does Anyone Have Experience Creating an Occasionally-Connected Browser App With NHibernate?

不打扰是莪最后的温柔 提交于 2019-12-06 12:05:04
We need to make our enterprise ASP.NET/NHibernate browser-based application able to function when connected to or disconnected from the customer's server. Has anyone done this? If so, how did you do it? (Technology, architecture, etc.) Background: We develop and sell an enterprise browser-based application used by construction field personnel to enter timesheet information. Currently, it requires a connection to the server back in the customer's office and we'd like to build an occasionally-connected version of the application for those clients without wireless Internet availability. Our

Sync Framework: Can you sync over http

南楼画角 提交于 2019-12-06 11:15:31
We are planning to use Sync Services for ADO.NET to sync stores with headoffice and it has been suggested that I sync via a WCF proxy . Does syncing via a WCF proxy mean that I will be able to sync over http ? If not, is it possible to use sync services to sync via http. (I do not want to update our firewall every time we get a new store that needs to sync with the headoffice -- that is why I want to sync via http). Yes, WCF implments both SOAP and REST webservices, either can which can be exposed over http or http/s. Here's some documentation from MSDN on WCF. We always use http/s (SSL), even

SyncFramework 2.1 updates & deletes do not seem to apply properly

不问归期 提交于 2019-12-06 07:29:46
I'm synchronizing SQL Server 2008 with ~6 SQL Server 2008 Express clients (everything R2 I believe), using the SyncOrchestrator or specifically using http://code.msdn.microsoft.com/windowsdesktop/Database-SyncSQL-Server-e97d1208 as a base with slight modifications. To my knowledge this means all connections are peers or nodes. I have 2 scopes. One is download only and the other is upload only. The download only scope is ridden with identity columns primarily because I didn't know any better and still couldn't wrap my head around introducing Guids as the PK on the client side. It doesn't