데이터베이스에 대한 모든 의존성 조회

1761 단어 데이터베이스
저장 프로세스, 보기 등과 관련된 모든 표
 
SELECT 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

좋은 웹페이지 즐겨찾기