none
GenerateSnapShot - The specified table does not exist. [ scope_info ] RRS feed

  • Question

  • Hi,

    I'm using Visual Studio 2010 designer to configure database sync and generate the database.    I try to create a snapshot in code and I get this error:

    The specified table does not exist. [ scope_info ]

    I'm using Syn Framework 2.0 and SQL Compact Edition SP2.

    Thanks in advance.

    Terry

    Monday, April 26, 2010 3:45 AM

Answers

  • if you used the designer to generate the code, that uses SQLCEClientSyncProvider and not the SQLCESyncProvider.

    So you cant use SQLCESyncStoreSnapshotInitialization's GenerateSnapshot as the SDF file was not provisioned using SqlCESyncScopeProvisioning thus the scope_info table is missing and so are the other database objects for metadata and change tracking.

    the peer-to-peer/collaboration providers has no designer support so you have to code the provisioning part, see http://msdn.microsoft.com/en-us/library/dd918848(SQL.105).aspx

    • Proposed as answer by Jandeep Monday, April 26, 2010 4:45 PM
    • Marked as answer by TerryAtHumming Monday, April 26, 2010 6:59 PM
    Monday, April 26, 2010 9:14 AM
    Moderator

All replies

  • can you post the code?

    The designer uses the SQLCEClientSyncProvider, are you trying to use the SQLCESyncProvider instead?

    Monday, April 26, 2010 4:08 AM
    Moderator
  • Here's the code.

    SqlCeConnection con= new SqlCeConnection(Properties.Settings.Default.ClientAppCacheDBConnectionString);
    SqlCeSyncStoreSnapshotInitialization snapshot = new SqlCeSyncStoreSnapshotInitialization();
    snapshot.GenerateSnapshot(con, "AppCacheDBSnap.sdf");

    Thanks

    Terry
    Monday, April 26, 2010 4:23 AM
  • if you used the designer to generate the code, that uses SQLCEClientSyncProvider and not the SQLCESyncProvider.

    So you cant use SQLCESyncStoreSnapshotInitialization's GenerateSnapshot as the SDF file was not provisioned using SqlCESyncScopeProvisioning thus the scope_info table is missing and so are the other database objects for metadata and change tracking.

    the peer-to-peer/collaboration providers has no designer support so you have to code the provisioning part, see http://msdn.microsoft.com/en-us/library/dd918848(SQL.105).aspx

    • Proposed as answer by Jandeep Monday, April 26, 2010 4:45 PM
    • Marked as answer by TerryAtHumming Monday, April 26, 2010 6:59 PM
    Monday, April 26, 2010 9:14 AM
    Moderator