SQL SERVER获取表在哪些存储过程中使用过
1.获取某张表在哪些存储过程中使用到
select distinct object_name(id) from syscomments where id in (select object_id from sys.objects where type ='P') and text like'%tableName%'
2.获取某张表的创建时间
select * from sys.tables where name ='tableName ' order by create_date desc
3.查询存储过程创建时间
select * from sys.procedures WHERE name = 'proc_name'