Reputation: 141
I am using a SQL Server Compact database for a project I am working on and have been having a hard time trying to insert data to the database.
My insert statement and everything is working fine and data gets inserted too and I can even do searches for the inserted data (while in the application).
The problem I am having is when I quit and re-run the application, it seems that the data was not inserted into the database and the tables are empty too.
Can anyone let me know where I am going wrong with this?
Thanks
Upvotes: 0
Views: 83
Reputation: 4987
As Thorsten pointed out, check the Build Action on your SDF file.
Upvotes: 0
Reputation: 56727
Could it be that the SDF file is overwritten with an empty version whenever you rebuild/run the application?
Upvotes: 3