How to get list of database objects for finding specific tables used in stored procedure or functions.

 Posted by vishalneeraj-24503 on 1/3/2015 | Category: Sql Server Interview questions | Views: 1619 | Points: 40
Answer:

Write below Query.Below query will return list of user defined tables,stored procedures and functions.

select distinct B.name 

from syscomments A
inner join sys.objects B
on A.id = B.object_id
where A.text like '%your_table_name%';


Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Login to post response