Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 336211
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T10:13:16+00:00 2026-05-12T10:13:16+00:00

How to do a global search for a key word in all the Stored

  • 0

How to do a global search for a key word in all the Stored Proc’s for a given DB?

I used the following but I am unable to get the desired results…

SELECT name 
FROM sysobjects 
WHERE id IN 
  ( 
    SELECT id 
    FROM syscolumns 
    WHERE name = 'loadStatus' COLLATE SQL_Latin1_General_CP1_CI_AS 
  ) 

SELECT name 
FROM sysobjects 
WHERE id IN 
  ( 
    SELECT id 
    FROM syscolumns 
    WHERE name like '%loadStatus%' COLLATE SQL_Latin1_General_CP1_CI_AS
  )

Regards
-Vas

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T10:13:16+00:00Added an answer on May 12, 2026 at 10:13 am

    Have a look at this link – http://www.sqlservercentral.com/scripts/T-SQL+Aids/31131/ and see if that helps.

    The SP in the linked article was written by Prasad Bhogadi and is as follows:

    CREATE PROCEDURE SEARCHFORSTRING @SEARCHSTRING VARCHAR(100)
    AS
                SELECT  DISTINCT(sysobjects.name)
                    FROM 
                    sysobjects,syscomments
                WHERE 
                    sysobjects.id =     syscomments.id
                AND 
                    sysobjects.type = 'P'
                AND 
                    sysobjects.category=0
    AND
            CHARINDEX(@SEARCHSTRING ,syscomments.text)>0
    

    You can use this to create an SP in your database or adapt it for a one-time query.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to allow a global search across all fields defined in my solr
I wan't to make a global search on a set of classes but I
I'm implementing global search box extension (sth like SearchableDictionary sample in android sdk). Everything
I want to implement the Global search for the Leads for the Primary address
How can I add a database field to the Magento global search? I want
I am making a binary search tree (BST) and a randomized BST. All of
This is for a search facility on a website. I have it all working
I can set global search directories for headers and libraries in VC++ Tools->Options->Projects and
I need to provide some kind of global search over most of the data
How can change this behaviour: C-s — start incremental search type word — misprint

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.