且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

“操作必须使用可更新的查询”。部署后

更新时间:2023-02-14 22:30:30

如果安装程序将数据库文件与可执行文件放在同一文件夹中,例如 C:CProgram Files\myApp \ ,那么普通用户将仅具有对数据库的只读访问权限:

If your installer is placing the database file in the same folder as the executable file(s), e.g., C:\Program Files\myApp\ then regular users will only have read-only access to the database:

即使您的安装程序修改了数据库 file 的权限, ,普通用户仍将具有对数据库的只读访问权限,因为他们在文件夹 ...

Even if your installer modifies the permissions on the database file, regular users will still have read-only access to the database because they have read-only access on the folder...

...而您绝对不会希望对常规用户对该文件夹打开读写访问权限。 (有关文件/文件夹权限对Jet / ACE数据库的影响的详细信息,请参阅我的回答在这里。)

...and you definitely do NOT want to open up read-write access on that folder to regular Users. (For details on the effect of file/folder permissions on Jet/ACE databases, see my answer here.)

相反,您的安装程序应该将数据库文件放在普通用户通常具有读写访问权限的文件夹中,也许在%PUBLIC%下。

Instead, your installer should be putting the database file into a folder where regular users normally have read-write access, perhaps somewhere under %PUBLIC%.