verify creation of database objects such as triggers, procedures , permissions

一世执手 提交于 2019-12-31 05:07:09

问题


I am creating triggers & procedures on a table from a winform application which uses sql server 2005 express.

I want that when the user clicks the create trigger/procedure button, then it creates both the objects & displays on a new Form that triggers & procedures are created with the names and tables on which they are created.

I mean that how do i verify that the objects are created. i want to verify and show it to the user that the objects are created on the so and so table.


回答1:


After your CREATE XXX ..., you can run SELECT OBJECT_ID('XXX')

Of course, if you have no error the object exists anyway



来源:https://stackoverflow.com/questions/5126017/verify-creation-of-database-objects-such-as-triggers-procedures-permissions

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