P_CtlgSlsProdHierNodeVH

DDL: P_CTLGSLSPRODHIERNODEVH Type: view_entity COMPOSITE

P_CtlgSlsProdHierNodeVH is a Composite CDS View in SAP S/4HANA. It reads from 1 data source (hrrp_directory) and exposes 6 fields with key fields ProductHierarchy, ProductHierarchyNode, ProdHierarchyValidityEndDate, SalesOrganization, DistributionChannel. It has 1 association to related views.

Data Sources (1)

SourceAliasJoin Type
hrrp_directory hierarchy from

Associations (1)

CardinalityTargetAliasCondition
[0..1] I_ProdUnivHierNodeText_2 _Text _Text.ProdUnivHierarchy = hierarchy.hrysid and _Text.HierarchyNode = node.hrynode and _Text.ProdHierarchyValidityEndDate = hierarchy.hryvalto and _Text.Language = $session.system_language

Annotations (6)

NameValueLevelField
VDM.private true view
AccessControl.authorizationCheck #CHECK view
VDM.viewType #COMPOSITE view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.dataClass #MASTER view

Fields (6)

KeyFieldSource TableSource FieldDescription
KEY ProductHierarchy
KEY ProductHierarchyNode node nodevalue Value
KEY ProdHierarchyValidityEndDate
KEY SalesOrganization dcassignment SalesOrganization Sales Organization
KEY DistributionChannel dcassignment DistributionChannel RefDistCh-Cust/Mat.
ProdUnivHierarchyNodeText _Text ProdUnivHierarchyNodeText

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 P_CtlgSlsProdHierNodeVH.
-- 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 P_CtlgSlsProdHierNodeVH AS
SELECT
  cast(hierarchy.hrysid as prod_hier_id preserving type ) AS ProductHierarchy,
  node.nodevalue AS ProductHierarchyNode,
  max(hierarchy.hryvalto) AS ProdHierarchyValidityEndDate,
  dcassignment.SalesOrganization AS SalesOrganization,
  dcassignment.DistributionChannel AS DistributionChannel,
  _Text.ProdUnivHierarchyNodeText AS ProdUnivHierarchyNodeText
FROM hrrp_directory AS hierarchy
LEFT OUTER JOIN I_ProdUnivHierNodeText_2 AS _Text ON _Text.ProdUnivHierarchy = hierarchy.hrysid AND _Text.HierarchyNode = node.hrynode AND _Text.ProdHierarchyValidityEndDate = hierarchy.hryvalto AND _Text.Language = $session.system_language  -- association [0..1]
;