Force INSERT only via stored procedure

后端 未结 4 1307
抹茶落季
抹茶落季 2021-01-11 18:22

Using SQL Server 2008, is there a way to allow inserts to a table only via a stored procedure, and if so how?

EDIT:
The best way to go is probab

4条回答
  •  迷失自我
    2021-01-11 19:13

    Use permissions (grants). Create the SP and grant the execute right to the user or role in question. Then deny the insert right on the table an you should be all set.

提交回复
热议问题