Click here to Skip to main content
11,796,631 members (74,393 online)
Click here to Skip to main content

How to Find a Text in SQL Server Stored Procedure

, 30 Jun 2012 CPOL 19.9K 4
Rate this:
Please Sign up or sign in to vote.
This article describes How to find a Text in Stored Procedure (Checked on SQL Server 2008)


This article describes How to find a Text in Stored Procedure (Checked on SQL Server 2008)


Need to delete or rename a Column Name in Table? 100's of Stored Procedures? Running short on time? Constraints may save you by generating an warning but Stored Procedure Won't!

Here is an awesome Trick that may save your time!

This applies to non encrypted stored procedues only.

  • Open SQL Server Management Studio
  • Make sure that you have permission to access the database objects
  • Select the Database which has Stored Procedure in which you need to find Text
  • Click on New Query
  • Below query searches for Text Product and Order [You can use AND or OR and more]

Using the code

SELECT Name as [Stored Procedure Name]
FROM sys.procedures

Screen Shot


I am working on Find and Replace version of above example once done will post here. Enjoy

This article was posted on my blog added here with some enhancement


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

India India
I am a Tech Lead / .Net Architect,

I love working with Business Challenges, Requirements

I work mainly for Designing eCommerce Portals Using ASP.Net enabled Frameworks such as Mediachase, zNode and Storefront.

I love writing my Articles at Code Project and my site

You may also be interested in...

Comments and Discussions

GeneralMy vote of 3 Pin
Corvus Corax8-Apr-13 6:47
memberCorvus Corax8-Apr-13 6:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.151002.1 | Last Updated 30 Jun 2012
Article Copyright 2012 by SmartCodar
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid