I_CompanyCodeHierarchy
Company Code Hierarchy
I_CompanyCodeHierarchy is a Basic CDS View (Dimension) that provides data about "Company Code Hierarchy" in SAP S/4HANA. It reads from 1 data source (hrrp_dir_n) and exposes 8 fields with key fields CompanyCodeHierarchy, ValidityEndDate. It has 1 association to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| hrrp_dir_n | hrrp_dir_n | from |
Associations (1)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [1..*] | I_CompanyCodeHierarchyT | _Text | $projection.CompanyCodeHierarchy = _Text.CompanyCodeHierarchy and $projection.ValidityEndDate = _Text.ValidityEndDate |
Annotations (15)
| Name | Value | Level | Field |
|---|---|---|---|
| EndUserText.label | Company Code Hierarchy | view | |
| ObjectModel.representativeKey | CompanyCodeHierarchy | view | |
| Analytics.dataCategory | #DIMENSION | view | |
| VDM.viewType | #BASIC | view | |
| AbapCatalog.sqlViewName | IFICOCODEH | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| Metadata.allowExtensions | true | view | |
| ObjectModel.modelingPattern | #ANALYTICAL_DIMENSION | view | |
| Metadata.ignorePropagatedAnnotations | true | view | |
| AbapCatalog.preserveKey | true | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| ObjectModel.usageType.dataClass | #MASTER | view | |
| ObjectModel.usageType.serviceQuality | #A | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| Analytics.dataExtraction.enabled | true | view |
Fields (8)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CompanyCodeHierarchy | |||
| KEY | ValidityEndDate | |||
| ValidityStartDate | ||||
| LastChangedByUser | hrrp_dir_n | upduser | ||
| LastChangeDateTime | hrrp_dir_n | updtime | ||
| LastChangeTime | hrrp_dir_n | updtime | ||
| HierarchyShortID | hrrp_dir_n | hrysid | ||
| _Text | _Text |
@EndUserText.label: 'Company Code Hierarchy'
@ObjectModel.representativeKey: 'CompanyCodeHierarchy' //Inserted by VDM CDS Suite Plugin
@Analytics: { dataCategory: #DIMENSION }
@VDM.viewType: #BASIC
@AbapCatalog.sqlViewName: 'IFICOCODEH'
@AccessControl.authorizationCheck: #CHECK
@Metadata.allowExtensions:true
@ObjectModel.modelingPattern: #ANALYTICAL_DIMENSION
@ObjectModel.supportedCapabilities: [ #CDS_MODELING_DATA_SOURCE, #CDS_MODELING_ASSOCIATION_TARGET, #ANALYTICAL_DIMENSION, #EXTRACTION_DATA_SOURCE ]
@Metadata.ignorePropagatedAnnotations:true
@AbapCatalog.compiler.compareFilter
@AbapCatalog.preserveKey:true
@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType: {
dataClass: #MASTER,
serviceQuality: #A,
sizeCategory: #XL
}
@Analytics.dataExtraction.enabled: true
define view I_CompanyCodeHierarchy
as select from hrrp_dir_n
association [1..*] to I_CompanyCodeHierarchyT as _Text on $projection.CompanyCodeHierarchy = _Text.CompanyCodeHierarchy
and $projection.ValidityEndDate = _Text.ValidityEndDate
{
@ObjectModel.text.association: '_Text'
key cast ( hrrp_dir_n.hryid_42 as fis_hryid_ccode_42 preserving type ) as CompanyCodeHierarchy,
@Semantics.businessDate.to: true
key cast(hrrp_dir_n.hryvalto as fis_datbi preserving type ) as ValidityEndDate,
@Semantics.businessDate.from: true
cast(hrrp_dir_n.hryvalfrom as fis_datab preserving type ) as ValidityStartDate,
@Semantics.user.lastChangedBy: true
hrrp_dir_n.upduser as LastChangedByUser,
@Semantics.systemDateTime.lastChangedAt: true
hrrp_dir_n.updtime as LastChangeDateTime,
@API.element.releaseState: #DEPRECATED
@API.element.successor: 'LastChangeDateTime'
@VDM.lifecycle.status: #DEPRECATED
@VDM.lifecycle.successor: 'LastChangeDateTime'
//@Semantics.systemDate.lastChangedAt: true
hrrp_dir_n.updtime as LastChangeTime,
hrrp_dir_n.hrysid as HierarchyShortID,
_Text
}
where
hrrp_dir_n.hrytyp = 'COCD';
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"HRRP_DIR_N"
],
"ASSOCIATED":
[
"I_COMPANYCODEHIERARCHYT"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/
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