P_CntrlPurchasingSpnd

DDL: P_CNTRLPURCHASINGSPND SQL: PCNTRLPURGSPND1 Type: view CONSUMPTION Package: ODATA_MM_PUR_HUB_PO_ANA

Central Purchasing Spend

P_CntrlPurchasingSpnd is a Consumption CDS View that provides data about "Central Purchasing Spend" in SAP S/4HANA. It reads from 1 data source (P_CentralPurgSpendEnhanced) and exposes 20 fields with key fields PurchaseOrder, PurchaseOrderItem, ScheduleLine, ProcurementHubSourceSystem. Part of development package ODATA_MM_PUR_HUB_PO_ANA.

Data Sources (1)

SourceAliasJoin Type
P_CentralPurgSpendEnhanced P_CentralPurgSpendEnhanced from

Parameters (3)

NameTypeDefault
P_DisplayCurrency displaycurrency
P_StartDate bedat
P_EndDate bedat

Annotations (10)

NameValueLevelField
AbapCatalog.sqlViewName PCNTRLPURGSPND1 view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #CHECK view
EndUserText.label Central Purchasing Spend view
VDM.private true view
VDM.viewType #CONSUMPTION view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.serviceQuality #D view
ObjectModel.usageType.sizeCategory #L view
AbapCatalog.preserveKey true view

Fields (20)

KeyFieldSource TableSource FieldDescription
KEY PurchaseOrder PurchaseOrder Purchasing Document
KEY PurchaseOrderItem PurchaseOrderItem Purchasing Document Item
KEY ScheduleLine ScheduleLine Schedule Line
KEY ProcurementHubSourceSystem ProcurementHubSourceSystem Connected System ID
FormattedPurchaseContractItem
Supplier Supplier Supplier
PurchasingOrganization PurchasingOrganization Purchasing Organization
PurchasingGroup PurchasingGroup Purchasing Group
CompanyCode CompanyCode Receiver Company Code
Material Material Vehicle Model
MaterialGroup MaterialGroup Product Group
Plant Plant Valuation Area
PurchaseOrderDate PurchaseOrderDate PO Date
PurchasingDocumentItemCategory PurchasingDocumentItemCategory Item Category
PurchaseOrderType PurchaseOrderType PO Type
CreatedByUser CreatedByUser User Name
CreatedByUserName CreatedByUserName Person Resp.
DisplayCurrency
SchedLineStscDeliveryDate SchedLineStscDeliveryDate Stat. Del. Date
NumberOfPurchaseOrders

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_CntrlPurchasingSpnd.
-- 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: PCNTRLPURGSPND1
-- Parameters: P_DisplayCurrency : displaycurrency, P_StartDate : bedat, P_EndDate : bedat

CREATE VIEW P_CntrlPurchasingSpnd AS
SELECT
  PurchaseOrder,
  PurchaseOrderItem,
  ScheduleLine,
  ProcurementHubSourceSystem,
  concat(PurchaseOrder,ProcurementHubSourceSystem) AS FormattedPurchaseContractItem,
  Supplier,
  PurchasingOrganization,
  PurchasingGroup,
  CompanyCode,
  Material,
  MaterialGroup,
  Plant,
  PurchaseOrderDate,
  PurchasingDocumentItemCategory,
  PurchaseOrderType,
  CreatedByUser,
  CreatedByUserName,
  cast( $parameters.P_DisplayCurrency as displaycurrency) AS DisplayCurrency,
  SchedLineStscDeliveryDate,
  cast( 1 as mm_pur_ana_numbrofpurords ) AS NumberOfPurchaseOrders
FROM P_CentralPurgSpendEnhanced
;