简体   繁体   English

使用SQL Server CE的问题

[英]Problems using SQL Server CE

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. 我正在为正在处理的项目使用SQL Server Compact数据库,并且在尝试将数据插入数据库时​​遇到了困难。

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 谢谢

每当您重建/运行应用程序时,SDF文件会被空版本覆盖吗?

正如Thorsten指出的那样,检查SDF文件上的Build Action。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM