Find strings in text of stored procedures

Ussualy this kind of scripts queries sysobjects and syscomments like this:select distinct object_name(O.id)from syscomments as Cjoin sysobjects as O on O.id = C.id and o.type = 'P' -- search string only in stored procedureswhere C.text like '%insert into MyTable%'When the text of stored procedures, triggers, functions is over 4000 characters, it is saved in syscomments […]

2004-08-26

160 reads

Blogs

VMworld 2020 – Top 10 Database Sessions (Part 2)

By

Whether you are a SQL Server Database Administrator, Infrastructure Architect, or any other member...

Daily Coping 25 Sep 2020

By

I started to add a daily coping tip to the SQLServerCentral newsletter and to...

VMworld 2020 – Top 10 Database Sessions (Part 1)

By

Whether you are a SQL Server Database Administrator, Infrastructure Architect, or any other member...

Read the latest Blogs

Forums

SQLServer Agent not sending dbmail on job completion

By maxo85

Hi Everyone! I have a problem with a SQL Server 2017 with dbmail. I...

Ignore the entire record if a matching record is found

By SQL_Hunt

Hello, Kindly guide me with the following code in T-SQL. I need to only...

New Stuff Can Be Scary

By Grant Fritchey

Comments posted to this topic are about the item New Stuff Can Be Scary

Visit the forum

Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers