Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
apantig
Posting Yak Master
104 Posts |
Posted - 2005-12-08 : 21:18:57
|
| I need to know how to FIND a stored procedure that has a command "Delete From [Check] Where CVNumber=xxxxxxx". How will I do this?PS:I dont like to generate a script for all 3083 s/p and then open it in query analyser. This will take to much time to generate and will slow down our process.Thank you. |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2005-12-08 : 21:45:44
|
search from syscomments.text and join with sysobjects to obtain the nameselect o.name, c.textfrom syscomments c inner join sysobjects oon c.id = o.idwhere c.text like '%Delete From [Check]%' from-----------------[KH]Guys, where are we right now ? |
 |
|
|
apantig
Posting Yak Master
104 Posts |
Posted - 2005-12-08 : 21:57:11
|
| Wow, I never knew this command.Thank you very much. |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2005-12-08 : 22:03:16
|
| one more note. Only works if your stored procedure is not encrypted-----------------[KH]Guys, where are we right now ? |
 |
|
|
apantig
Posting Yak Master
104 Posts |
Posted - 2005-12-08 : 22:12:14
|
| Ok, thanks for that NOTE.Khtan, is the command you gave me also possible if I need to know what tables have triggers?(how?)Thanks again. |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2005-12-08 : 22:37:45
|
this will be easierselect o.name, t.namefrom sysobjects t inner join sysobjects o on t.parent_obj = o.idwhere t.xtype = 'TR' -----------------[KH]Guys, where are we right now ? |
 |
|
|
|
|
|
|
|