C_CntrlPurContrHierHdrDistrTP
Central Purch Contr Hierarchy HDR Distr
C_CntrlPurContrHierHdrDistrTP is a Consumption CDS View that provides data about "Central Purch Contr Hierarchy HDR Distr" in SAP S/4HANA. It reads from 1 data source (I_CntrlPurContrHdrDistrTP) and exposes 44 fields with key fields CentralPurchaseContract, DistributionKey. It has 11 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_CntrlPurContrHdrDistrTP | CntrlPurContrHdrDistrTP | from |
Associations (11)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [1..1] | C_CntrlPurContrHierHdrTP | _CentralPurchaseContractTP | _CentralPurchaseContractTP.CentralPurchaseContract = $projection.CentralPurchaseContract |
| [1..1] | C_ProcmtHubPlantVH | _ProcmtHubPlantVH | _ProcmtHubPlantVH.ProcmtHubPlant = $projection.Plant and _ProcmtHubPlantVH.ProcurementHubSourceSystem = $projection.ProcurementHubSourceSystem and _ProcmtHubPlantVH.ProcmtHubCompanyCode = $projection.CompanyCode |
| [1..1] | C_ProcmtHubStorageLocationVH | _ProcmtHubStorageLocationVH | _ProcmtHubStorageLocationVH.Plant = $projection.Plant and _ProcmtHubStorageLocationVH.StorageLocation = $projection.StorageLocation and _ProcmtHubStorageLocationVH.ProcurementHubSourceSystem = $projection.ProcurementHubSourceSystem |
| [1..1] | C_ProcmtHubCntrlContrPurgGrpVH | _ProcmtHubPurgGrpVH | _ProcmtHubPurgGrpVH.PurchasingGroup = $projection.PurchasingGroup and _ProcmtHubPurgGrpVH.ProcurementHubSourceSystem = $projection.ProcurementHubSourceSystem |
| [0..1] | I_Currency | _DocumentCurrency | _DocumentCurrency.Currency = $projection.Currency |
| [1..1] | C_ProcmtHubPurgOrgVH | _ProcmtHubPurgOrgVH | _ProcmtHubPurgOrgVH.ProcmtHubPurchasingOrg = $projection.PurchasingOrganization and _ProcmtHubPurgOrgVH.ProcurementHubSourceSystem = $projection.ProcurementHubSourceSystem |
| [0..*] | I_PaymentTermsText | _PaymentTermsText | $projection.PaymentTerms = _PaymentTermsText.PaymentTerms |
| [0..*] | C_CntrlPurContrHierHdrPartTP | _CntrlPurContrHdrPartnerTP | $projection.CentralPurchaseContract = _CntrlPurContrHdrPartnerTP.CentralPurchaseContract and $projection.DistributionKey = _CntrlPurContrHdrPartnerTP.DistributionKey |
| [0..1] | C_PurgDocCatForOutlineAgrmtVH | _PurgDocCatForOutlineAgrmtVH | _PurgDocCatForOutlineAgrmtVH.PurchasingDocumentCategory = $projection.PurchasingDocumentCategory |
| [1..1] | C_ProcmtHubSchedgAgrmtTypeVH | _ProcmtHubSchedgAgrmtTypeVH | _ProcmtHubSchedgAgrmtTypeVH.PurchasingDocumentType = $projection.PurchasingDocumentType and _ProcmtHubSchedgAgrmtTypeVH.ProcurementHubSourceSystem = $projection.ProcurementHubSourceSystem |
| [1..1] | R_CentralPurchaseContract | _CentralPurchaseContract | $projection.CentralPurchaseContract = _CentralPurchaseContract.CentralPurchaseContract |
Annotations (18)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | CPCHIERHDRDISTR | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| EndUserText.label | Central Purch Contr Hierarchy HDR Distr | view | |
| VDM.viewType | #CONSUMPTION | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| ObjectModel.usageType.sizeCategory | #L | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| AccessControl.personalData.blocking | #REQUIRED | view | |
| AbapCatalog.preserveKey | true | view | |
| ObjectModel.createEnabled | true | view | |
| ObjectModel.deleteEnabled | true | view | |
| ObjectModel.updateEnabled | true | view | |
| ObjectModel.transactionalProcessingDelegated | true | view | |
| UI.headerInfo.typeName | Distribution | view | |
| UI.headerInfo.typeNamePlural | Distributions | view | |
| UI.headerInfo.description.value | CentralPurchaseContract | view |
Fields (44)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CentralPurchaseContract | CentralPurchaseContract | Purchasing Doc. | |
| KEY | DistributionKey | DistributionKey | Distr. Number | |
| ProcmtHubCompanyCodeGroupingID | ProcmtHubCompanyCodeGroupingID | Company Code Grouping ID | ||
| CentralPurchaseContractItem | CentralPurchaseContractItem | Item in Central Purchase Contract | ||
| ActivePurchasingDocument | _CentralPurchaseContract | ActivePurchasingDocument | Active Purchase Doc | |
| PurchasingDocumentName | _CentralPurchaseContract | PurchasingDocumentName | Purch. Doc. Name | |
| PurgDocChangeRequestStatus | _CentralPurchaseContract | PurgDocChangeRequestStatus | Change Request Stat. | |
| PurchasingDocumentCategory | PurchasingDocumentCategory | Doc. Category | ||
| PurchasingDocumentType | PurchasingDocumentType | RFQ Type | ||
| PurchasingInfoRecordUpdateCode | PurchasingInfoRecordUpdateCode | InfoUpdate | ||
| PurchasingOrganization | PurchasingOrganization | Purchasing Organization | ||
| CompanyCode | CompanyCode | Receiver Company Code | ||
| Plant | Plant | Valuation Area | ||
| StorageLocation | StorageLocation | StorageLocation | ||
| DocumentCurrency | DocumentCurrency | Document Currency | ||
| Currency | Currency | Connected System Currency | ||
| PurchasingGroup | PurchasingGroup | Purchasing Group | ||
| SourceListIsUpdated | SourceListIsUpdated | Source List Updated | ||
| SourceListRestriction | SourceListRestriction | Source List Restriction | ||
| LogicalSystem | LogicalSystem | Logical System | ||
| PaymentTerms | PaymentTerms | Pyt Terms | ||
| CashDiscount1Days | CashDiscount1Days | Days from Baseline Date for Payment | ||
| CashDiscount2Days | CashDiscount2Days | Days from Baseline Date for Payment | ||
| NetPaymentDays | NetPaymentDays | Net Pmt Terms Period | ||
| CashDiscount1Percent | CashDiscount1Percent | Disc. Percent 1 | ||
| CashDiscount2Percent | CashDiscount2Percent | Disc. Percent 2 | ||
| ShippingInstruction | ShippingInstruction | Shipping Instr. | ||
| IncotermsClassification | IncotermsClassification | Incoterms | ||
| IncotermsLocation1 | IncotermsLocation1 | Inco. Location1 | ||
| CntrlPurContrDistributionPct | CntrlPurContrDistributionPct | |||
| TargetAmount | TargetAmount | Target Value | ||
| TextIsDeleted | TRUE | |||
| ProcurementHubSourceSystem | ProcurementHubSourceSystem | Connected System ID | ||
| ProcmtHubLogicalSystem | ProcurementHubSourceSystem | Connected System ID | ||
| _CentralPurchaseContractTP | _CentralPurchaseContractTP | |||
| _CntrlPurContrHdrPartnerTP | _CntrlPurContrHdrPartnerTP | |||
| _DocumentCurrency | _DocumentCurrency | |||
| _ProcmtHubPurgOrgVH | _ProcmtHubPurgOrgVH | |||
| _ProcmtHubPlantVH | _ProcmtHubPlantVH | |||
| _ProcmtHubStorageLocationVH | _ProcmtHubStorageLocationVH | |||
| _ProcmtHubPurgGrpVH | _ProcmtHubPurgGrpVH | |||
| _PaymentTermsText | _PaymentTermsText | |||
| _PurgDocCatForOutlineAgrmtVH | _PurgDocCatForOutlineAgrmtVH | |||
| _ProcmtHubSchedgAgrmtTypeVH | _ProcmtHubSchedgAgrmtTypeVH |
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 C_CntrlPurContrHierHdrDistrTP.
-- 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.
-- SQL view name: CPCHIERHDRDISTR
CREATE VIEW C_CntrlPurContrHierHdrDistrTP AS
SELECT
CentralPurchaseContract,
DistributionKey,
ProcmtHubCompanyCodeGroupingID,
CentralPurchaseContractItem,
_CentralPurchaseContract.ActivePurchasingDocument AS ActivePurchasingDocument,
_CentralPurchaseContract.PurchasingDocumentName AS PurchasingDocumentName,
_CentralPurchaseContract.PurgDocChangeRequestStatus AS PurgDocChangeRequestStatus,
PurchasingDocumentCategory,
PurchasingDocumentType,
PurchasingInfoRecordUpdateCode,
PurchasingOrganization,
CompanyCode,
Plant,
StorageLocation,
DocumentCurrency,
Currency,
PurchasingGroup,
SourceListIsUpdated,
SourceListRestriction,
LogicalSystem,
PaymentTerms,
CashDiscount1Days,
CashDiscount2Days,
NetPaymentDays,
CashDiscount1Percent,
CashDiscount2Percent,
ShippingInstruction,
IncotermsClassification,
IncotermsLocation1,
CntrlPurContrDistributionPct,
TargetAmount,
cast(IsDeleted as boolean) AS TextIsDeleted,
ProcurementHubSourceSystem,
ProcurementHubSourceSystem AS ProcmtHubLogicalSystem
FROM I_CntrlPurContrHdrDistrTP AS CntrlPurContrHdrDistrTP
LEFT OUTER JOIN C_CntrlPurContrHierHdrTP AS _CentralPurchaseContractTP ON _CentralPurchaseContractTP.CentralPurchaseContract = CentralPurchaseContract -- association [1..1]
LEFT OUTER JOIN C_ProcmtHubPlantVH AS _ProcmtHubPlantVH ON _ProcmtHubPlantVH.ProcmtHubPlant = Plant AND _ProcmtHubPlantVH.ProcurementHubSourceSystem = ProcurementHubSourceSystem AND _ProcmtHubPlantVH.ProcmtHubCompanyCode = CompanyCode -- association [1..1]
LEFT OUTER JOIN C_ProcmtHubStorageLocationVH AS _ProcmtHubStorageLocationVH ON _ProcmtHubStorageLocationVH.Plant = Plant AND _ProcmtHubStorageLocationVH.StorageLocation = StorageLocation AND _ProcmtHubStorageLocationVH.ProcurementHubSourceSystem = ProcurementHubSourceSystem -- association [1..1]
LEFT OUTER JOIN C_ProcmtHubCntrlContrPurgGrpVH AS _ProcmtHubPurgGrpVH ON _ProcmtHubPurgGrpVH.PurchasingGroup = PurchasingGroup AND _ProcmtHubPurgGrpVH.ProcurementHubSourceSystem = ProcurementHubSourceSystem -- association [1..1]
LEFT OUTER JOIN I_Currency AS _DocumentCurrency ON _DocumentCurrency.Currency = Currency -- association [0..1]
LEFT OUTER JOIN C_ProcmtHubPurgOrgVH AS _ProcmtHubPurgOrgVH ON _ProcmtHubPurgOrgVH.ProcmtHubPurchasingOrg = PurchasingOrganization AND _ProcmtHubPurgOrgVH.ProcurementHubSourceSystem = ProcurementHubSourceSystem -- association [1..1]
LEFT OUTER JOIN I_PaymentTermsText AS _PaymentTermsText ON PaymentTerms = _PaymentTermsText.PaymentTerms -- association [0..*]
LEFT OUTER JOIN C_CntrlPurContrHierHdrPartTP AS _CntrlPurContrHdrPartnerTP ON CentralPurchaseContract = _CntrlPurContrHdrPartnerTP.CentralPurchaseContract AND DistributionKey = _CntrlPurContrHdrPartnerTP.DistributionKey -- association [0..*]
LEFT OUTER JOIN C_PurgDocCatForOutlineAgrmtVH AS _PurgDocCatForOutlineAgrmtVH ON _PurgDocCatForOutlineAgrmtVH.PurchasingDocumentCategory = PurchasingDocumentCategory -- association [0..1]
LEFT OUTER JOIN C_ProcmtHubSchedgAgrmtTypeVH AS _ProcmtHubSchedgAgrmtTypeVH ON _ProcmtHubSchedgAgrmtTypeVH.PurchasingDocumentType = PurchasingDocumentType AND _ProcmtHubSchedgAgrmtTypeVH.ProcurementHubSourceSystem = ProcurementHubSourceSystem -- association [1..1]
LEFT OUTER JOIN R_CentralPurchaseContract AS _CentralPurchaseContract ON CentralPurchaseContract = _CentralPurchaseContract.CentralPurchaseContract -- association [1..1]
;
Learn More
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- 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
- BSEG to ACDOCA: The Universal Journal Migration
- Business Partner Migration: KNA1/LFA1 to BUT000
- Material Document Migration: MSEG/MKPF to MATDOC
- How to Find the Right CDS View for an SAP Table
- BW Extractor to CDS View Migration Guide
- S/4HANA CDS View Deprecation: What You Need to Know
- ABAP CDS View Tutorial — From Basics to Real-World Examples
- RAP and CDS Views — Building Transactional Apps in SAP S/4HANA
- Sales Document Status Migration: VBUP/VBUK Removal in S/4HANA
- CO Tables in S/4HANA: COEP, COBK, COSS, COSP to ACDOCA