Back to all blogs3 min read
How to find Stored Procedures containing specific text in SQL Server?
Below small query will list all the procedures that contains specific text.
Ankush Jain
Lead Software Engineer (VP) | Software Architect
Published Sep 27, 2018Updated Nov 24, 2026
Below small query will list all the procedures that contains specific text.
SELECT OBJECT_NAME(object_id), definitionFROM sys.sql_modulesWHERE OBJECTPROPERTY(object_id, 'IsProcedure') = 1AND definition LIKE '%SearchText%'