Readonly connections with ADO.NET, SQLite and TSQL

ぃ、小莉子 提交于 2020-01-24 04:12:09

问题


My code reads via one connection and writes via another. I dont want to accidentally write with the read connection. How can i make the connection readonly? I am using SQLite ATM and will convert sections of code to tsql when the prototype is over.


回答1:


You can add Read Only=True to the read-only connection.

Data Source=filename;Read Only=True;


来源:https://stackoverflow.com/questions/2004010/readonly-connections-with-ado-net-sqlite-and-tsql

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!