0

I'm running SSMS 2008 and connecting to a database on a separate server.

I want to search through our stored procedures for specific strings of text. In Visual Studio 2010 this is simple, the quick find is able to look through the entire solution for the string. Not so in SSMS 2008.

In SQL Server it only searches through open queries. Meaning that I'd have to open the hundred or so queries and then run quick find. Does SQL Server not have the functionality to look through the stored procedures? I can't imagine that this is intentional.

When I try to search for anything without any queries open it gives me an error message:

Look in: A specified directory or file is not available or does not exist. 
3
  • stackoverflow.com/questions/9065598/… Commented Jun 23, 2015 at 0:48
  • I'm fairly certain that it's not built into SSMS. I use a tool by ApexSQL called ApexSql Search which is free. Commented Jun 23, 2015 at 0:50
  • That's unfortunate, then... I'll look into the tool Commented Jun 23, 2015 at 1:11

1 Answer 1

1

You mentioned you are are connecting to a database on a separate server. Do you have access to the .ssmssln solution file?

Otherwise, you can use this query to search stored procedure contents

c.f.: Search Text in Stored Procedure in SQL Server

SELECT name, definition FROM sys.sql_modules m INNER JOIN sys.objects o ON m.object_id = o.object_id WHERE m.definition Like '%search string%'; 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.