P_WBSHierarchyWithoutRootNode
WBS Hierarchy Without Root Node
P_WBSHierarchyWithoutRootNode is a Basic CDS View that provides data about "WBS Hierarchy Without Root Node" in SAP S/4HANA. It reads from 2 data sources (I_ProjectBasicData, prhi) and exposes 6 fields with key field WBSElementInternalID. It has 1 association to related views. Part of development package FINS_COPA_REPORTING.
Data Sources (2)
| Source | Alias | Join Type |
|---|---|---|
| I_ProjectBasicData | I_ProjectBasicData | inner |
| prhi | prhi | from |
Associations (1)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [1..1] | P_WBSHierarchyWithoutRootNode | _Parent | $projection.WBSElementParentInternalID = _Parent.WBSElementInternalID |
Annotations (5)
| Name | Value | Level | Field |
|---|---|---|---|
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| VDM.private | true | view | |
| EndUserText.label | WBS Hierarchy Without Root Node | view | |
| Metadata.ignorePropagatedAnnotations | true | view | |
| VDM.viewType | #BASIC | view |
Fields (6)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | WBSElementInternalID | prhi | posnr | |
| ProjectInternalID | prhi | psphi | ||
| WBSElementParentInternalID | prhi | up | ||
| CompanyCode | ||||
| WBSElementIsBillingElement | _ParentWBSElement | WBSElementIsBillingElement | ||
| _Parent | _Parent |
@AbapCatalog.viewEnhancementCategory: [#NONE]
@AccessControl.authorizationCheck: #NOT_REQUIRED
@VDM.private:true
@EndUserText.label: 'WBS Hierarchy Without Root Node'
@Metadata.ignorePropagatedAnnotations: true
@VDM.viewType: #BASIC
define view entity P_WBSHierarchyWithoutRootNode
// as select from prhi
// association [1..1] to I_WBSElementBasicData as _WBSElement on $projection.WBSElementInternalID = _WBSElement.WBSElementInternalID
// association [1..1] to I_ProjectBasicData as _Project on $projection.ProjectInternalID = _Project.ProjectInternalID
// association [1..1] to I_WBSElementBasicData as _ParentWBSElement on $projection.WBSElementParentInternalID = _ParentWBSElement.WBSElementInternalID
// association [1..1] to P_WBSHierarchyWithoutRootNode as _Parent on $projection.WBSElementParentInternalID = _Parent.WBSElementInternalID
//{
// key posnr as WBSElementInternalID,
// psphi as ProjectInternalID,
// up as WBSElementParentInternalID,
// _ParentWBSElement.WBSElementIsBillingElement as WBSElementIsBillingElement,
// _WBSElement,
// _ParentWBSElement,
// _Project,
// _Parent
//}
//where
// up is not initial
// //and _Project.ProjectProfileCode = 'YP05'
as select from prhi as prhi
inner join I_ProjectBasicData on prhi.psphi = I_ProjectBasicData.ProjectInternalID
and I_ProjectBasicData.ProjectProfileCode = 'YP05'
left outer to one join I_WBSElementBasicData as _ParentWBSElement on prhi.up = _ParentWBSElement.WBSElementInternalID
and _ParentWBSElement.WBSElementIsBillingElement = 'X'
and _ParentWBSElement.ProjectInternalID = I_ProjectBasicData.ProjectInternalID
// and _ParentWBSElement.CompanyCode = I_ProjectBasicData.CompanyCode
association [1..1] to P_WBSHierarchyWithoutRootNode as _Parent on $projection.WBSElementParentInternalID = _Parent.WBSElementInternalID
{
key prhi.posnr as WBSElementInternalID,
prhi.psphi as ProjectInternalID,
prhi.up as WBSElementParentInternalID,
cast ( I_ProjectBasicData.CompanyCode as ps_vbukr preserving type ) as CompanyCode,
// I_ProjectBasicData.CompanyCode,
_ParentWBSElement.WBSElementIsBillingElement as WBSElementIsBillingElement,
// _Project,
_Parent
}
where
prhi.up is not initial
Learn More
- What Is a CDS View in SAP S/4HANA?
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- CDS View Annotations — A Complete Guide
- CDS View Field Mapping and Associations
- Understanding the SAP S/4HANA Data Model
- CDS View Extensions and Custom Fields in SAP S/4HANA
- Released APIs and Stability Contracts in SAP S/4HANA