I_LglCntntMRelatedDocument

DDL: I_LGLCNTNTMRELATEDDOCUMENT Type: view_entity COMPOSITE Package: VDM_LCM_DOC

Related Document

I_LglCntntMRelatedDocument is a Composite CDS View that provides data about "Related Document" in SAP S/4HANA. It reads from 2 data sources (I_LegalDocument, I_LegalDocument) and exposes 63 fields with key field LglCntntMDocumentUUID. It has 4 associations to related views. Part of development package VDM_LCM_DOC.

Data Sources (2)

SourceAliasJoin Type
I_LegalDocument I_LegalDocument from
I_LegalDocument I_LegalDocument union

Associations (4)

CardinalityTargetAliasCondition
[1..1] I_LegalDocument _LCMDocument $projection.LglCntntMRelatedDocument = _LCMDocument.LglCntntMDocument and _LCMDocument.LglCntntMDocumentIsTopVersion = 'X' and _LCMDocument.LglCntntMDocIsToBeDeleted = ' '
[0..1] I_LCMUserAddressAssignment _CreatedBy $projection.LglCntntMCreatedByUser = _CreatedBy.ContactCardID
[0..1] I_LCMUserAddressAssignment _ChangedBy $projection.LglCntntMChangedByUser = _ChangedBy.ContactCardID
[0..1] C_LglCntntMGovLawVH _LCMGovLawVH $projection.LglCntntMGovLaw = _LCMGovLawVH.LglCntntMGovLaw

Annotations (14)

NameValueLevelField
AccessControl.authorizationCheck #MANDATORY view
VDM.viewType #COMPOSITE view
Metadata.ignorePropagatedAnnotations true view
AccessControl.personalData.blocking #REQUIRED view
ObjectModel.representativeKey LglCntntMDocumentUUID view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #M view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
EndUserText.label Related Document view
UI.headerInfo.typeName Related Document view
UI.headerInfo.typeNamePlural Related Documents view
UI.headerInfo.title.value DocumentDescription view
UI.headerInfo.description.value LglCntntMRelatedDocument view
VDM.lifecycle.contract.type #SAP_INTERNAL_API view

Fields (63)

KeyFieldSource TableSource FieldDescription
KEY LglCntntMDocumentUUID _LCMDocument LglCntntMDocumentUUID Universal Unique ID
LglCntntMDocument LglCntntMDocument Document ID
LegalTransactionUUID LegalTransactionUUID Universal Unique ID
LglCntntMDocAccessLvl _LCMDocument LglCntntMDocAccessLvl Acs. Level
LglCntntMDocContentType _LCMDocument LglCntntMDocContentType Content Type
LglCntntMDocContentTypeName
LglCntntMLanguage _LCMDocument LglCntntMLanguage Language
LanguageName
LglCntntMChangedByUser _LCMDocument LglCntntMChangedByUser Changed By
LglCntntMChangedUTCDateTime _LCMDocument LglCntntMChangedUTCDateTime Changed On
LglCntntMCreatedByUser _LCMDocument LglCntntMCreatedByUser Created By
LglCntntMCreatedUTCDateTime _LCMDocument LglCntntMCreatedUTCDateTime Created On
DocumentDescription _LCMDocument DocumentDescription Doc. Name
InternalDocumentStatus _LCMDocument InternalDocumentStatus Status
LglCntntMDocStatusName
LegalDocumentVersion _LCMDocument LegalDocumentVersion Docu. Version
LegalTransaction _LCMDocument LegalTransaction Legal Transaction ID
IsEndOfPurposeBlocked _LCMDocument IsEndOfPurposeBlocked Busin. Purp. Cmpltd.
LglCntntMIsMandatory _LCMDocument LglCntntMIsMandatory Is Mandatory
LglCntntMDocType _LCMDocument LglCntntMDocType Document Type
LglCntntMProfile
LglCntntMGovLaw
LglCntntMContextUUID
LegalTransactionTitle
LglCntntMNmbrOfAdminvDocUpdt _LCMDocument LglCntntMNmbrOfAdminvDocUpdt No of Admin Update
LglCntntMRelatedDocument LglCntntMParentDocument Document ID
LglCntntMDocumentKind _LCMDocument LglCntntMDocumentKind Document Kind
LglCntntMDocumentKindText
LglCntntMRelatedDocumentType
_LegalTransaction _LegalTransaction
_ChangedBy _ChangedBy
_CreatedBy _CreatedBy
LglCntntMDocument LglCntntMDocument Document ID
LegalTransactionUUID LegalTransactionUUID Universal Unique ID
LglCntntMDocAccessLvl _LCMDocument LglCntntMDocAccessLvl Acs. Level
LglCntntMDocContentType _LCMDocument LglCntntMDocContentType Content Type
LglCntntMDocContentTypeName
LglCntntMLanguage _LCMDocument LglCntntMLanguage Language
LanguageName
LglCntntMChangedByUser _LCMDocument LglCntntMChangedByUser Changed By
LglCntntMChangedUTCDateTime _LCMDocument LglCntntMChangedUTCDateTime Changed On
LglCntntMCreatedByUser _LCMDocument LglCntntMCreatedByUser Created By
LglCntntMCreatedUTCDateTime _LCMDocument LglCntntMCreatedUTCDateTime Created On
DocumentDescription _LCMDocument DocumentDescription Doc. Name
InternalDocumentStatus _LCMDocument InternalDocumentStatus Status
LglCntntMDocStatusName
LegalDocumentVersion _LCMDocument LegalDocumentVersion Docu. Version
LegalTransaction _LCMDocument LegalTransaction Legal Transaction ID
IsEndOfPurposeBlocked _LCMDocument IsEndOfPurposeBlocked Busin. Purp. Cmpltd.
LglCntntMIsMandatory _LCMDocument LglCntntMIsMandatory Is Mandatory
LglCntntMDocType _LCMDocument LglCntntMDocType Document Type
LglCntntMProfile
LglCntntMGovLaw
LglCntntMContextUUID
LegalTransactionTitle
LglCntntMNmbrOfAdminvDocUpdt _LCMDocument LglCntntMNmbrOfAdminvDocUpdt No of Admin Update
LglCntntMRelatedDocument _LCMDocument LglCntntMDocument Document ID
LglCntntMDocumentKind _LCMDocument LglCntntMDocumentKind Document Kind
LglCntntMDocumentKindText
_LegalTransaction _LegalTransaction
_ChangedBy _ChangedBy
_CreatedBy _CreatedBy
_LCMGovLawVH _LCMGovLawVH

Derived SQL interpretation, reconstructed from the parsed view metadata (data sources, associations, and field mappings). SAP annotations are omitted and the structure is reformulated as SQL — this is a functional approximation, not the verbatim SAP source.

-- Derived SQL interpretation of CDS view I_LglCntntMRelatedDocument.
-- Reconstructed from parsed metadata (data sources, associations, fields).
-- SAP annotations are omitted and the structure is reformulated as SQL;
-- this is a functional approximation, not the verbatim SAP source. Some join
-- conditions may be unavailable and a few CDS constructs are kept as-is.

CREATE VIEW I_LglCntntMRelatedDocument AS
SELECT
  _LCMDocument.LglCntntMDocumentUUID AS LglCntntMDocumentUUID,
  LglCntntMDocument,
  LegalTransactionUUID,
  _LCMDocument.LglCntntMDocAccessLvl AS LglCntntMDocAccessLvl,
  _LCMDocument.LglCntntMDocContentType AS LglCntntMDocContentType,
  _LCMDocument._ContentTypeText[1: Language = $session.system_language].LglCntntMDocContentTypeName AS LglCntntMDocContentTypeName,
  _LCMDocument.LglCntntMLanguage AS LglCntntMLanguage,
  _LCMDocument._LanguageText[1: Language = $session.system_language].LanguageName AS LanguageName,
  _LCMDocument.LglCntntMChangedByUser AS LglCntntMChangedByUser,
  _LCMDocument.LglCntntMChangedUTCDateTime AS LglCntntMChangedUTCDateTime,
  _LCMDocument.LglCntntMCreatedByUser AS LglCntntMCreatedByUser,
  _LCMDocument.LglCntntMCreatedUTCDateTime AS LglCntntMCreatedUTCDateTime,
  _LCMDocument.DocumentDescription AS DocumentDescription,
  _LCMDocument.InternalDocumentStatus AS InternalDocumentStatus,
  _LCMDocument._DocStatusText[1: Language = $session.system_language].LglCntntMDocStatusName AS LglCntntMDocStatusName,
  _LCMDocument.LegalDocumentVersion AS LegalDocumentVersion,
  _LCMDocument.LegalTransaction AS LegalTransaction,
  _LCMDocument.IsEndOfPurposeBlocked AS IsEndOfPurposeBlocked,
  _LCMDocument.LglCntntMIsMandatory AS LglCntntMIsMandatory,
  _LCMDocument.LglCntntMDocType AS LglCntntMDocType,
  _LCMDocument._LegalTransaction.LglCntntMProfile AS LglCntntMProfile,
  _LCMDocument._LegalTransaction.LglCntntMGovLaw AS LglCntntMGovLaw,
  _LCMDocument._LegalTransaction.LglCntntMContextUUID AS LglCntntMContextUUID,
  _LCMDocument._LegalTransaction.LegalTransactionTitle AS LegalTransactionTitle,
  _LCMDocument.LglCntntMNmbrOfAdminvDocUpdt AS LglCntntMNmbrOfAdminvDocUpdt,
  LglCntntMParentDocument AS LglCntntMRelatedDocument,
  _LCMDocument.LglCntntMDocumentKind AS LglCntntMDocumentKind,
  _LCMDocument._DocumentKindText[1: Language = $session.system_language].LglCntntMDocumentKindText AS LglCntntMDocumentKindText,
  cast('P' as lcm_document_related_type ) AS LglCntntMRelatedDocumentType
FROM I_LegalDocument
LEFT OUTER JOIN I_LegalDocument AS _LCMDocument ON LglCntntMRelatedDocument = _LCMDocument.LglCntntMDocument AND _LCMDocument.LglCntntMDocumentIsTopVersion = 'X' AND _LCMDocument.LglCntntMDocIsToBeDeleted = ' '  -- association [1..1]
LEFT OUTER JOIN I_LCMUserAddressAssignment AS _CreatedBy ON LglCntntMCreatedByUser = _CreatedBy.ContactCardID  -- association [0..1]
LEFT OUTER JOIN I_LCMUserAddressAssignment AS _ChangedBy ON LglCntntMChangedByUser = _ChangedBy.ContactCardID  -- association [0..1]
LEFT OUTER JOIN C_LglCntntMGovLawVH AS _LCMGovLawVH ON LglCntntMGovLaw = _LCMGovLawVH.LglCntntMGovLaw  -- association [0..1]
-- UNION with additional select branch(es): I_LegalDocument
;