So you have decided that you want to incorporate SQL server CE into your application. I found out that almost every Smart Client or Desktop based Rich application need a way to cache data and Sql Server CE is a great tool to do just that.
Sql Compact Edition has a few advantages that might sway you if you still don’t think it is necessary. But the main problem most people while considering a transition to CE that you need to create a schema from an existing DB and the IDE lacks this ability up to now;
You just can’t run a “Create” script on it from the IDE.
To solve this issue you can use this simple nice trick: We will be using the Sync framework to build our local CE db for you.
To do so you need to open VS 2008 (SP1).
- Create a new project (doesn’t matter which one).
- Create New Item –> Local Database cache
- Choose your Connection to the source database
- Add the tables you want to create on your compact edition
- click OK.
- and here you go, the wizard will create the local Sql Server CE database file for you.