查询函数在哪些存储过程中使用

SELECT OBJECT_SCHEMA_NAME ( referencing_id ) AS referencing_schema_name,
      OBJECT_NAME(referencing_id) AS referencing_entity_name, 
      o.type_desc AS referencing_desciption, 
      COALESCE(COL_NAME(referencing_id, referencing_minor_id), '(n/a)') AS referencing_minor_id, 
      referencing_class_desc, referenced_class_desc,
      referenced_server_name, referenced_database_name, referenced_schema_name,
      referenced_entity_name, 
      COALESCE(COL_NAME(referenced_id, referenced_minor_id), '(n/a)') AS referenced_column_name,
      is_caller_dependent, is_ambiguous
  FROM sys.sql_expression_dependencies AS sed
  INNER JOIN sys.objects AS o ON sed.referencing_id = o.object_id
  WHERE referenced_id = OBJECT_ID(N'Function Name');
  
  
select *
from sys.sql_modules
where definition like '%Function Name%'
阅读更多
个人分类: SQL SERVER 工具
下一篇动态生成层级字段
博主设置当前文章不允许评论。

没有更多推荐了,返回首页

关闭
关闭