Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save LetsGoRafting/cb302869068ed789e497ac7780690ddd to your computer and use it in GitHub Desktop.
Save LetsGoRafting/cb302869068ed789e497ac7780690ddd to your computer and use it in GitHub Desktop.
find text in procedures functions views triggers
SELECT [Schema] = schema_name(o.schema_id), o.Name, o.type
FROM sys.sql_modules m
INNER JOIN sys.objects o ON o.object_id = m.object_id
WHERE m.definition like '%mytexttofind%'
GO
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment