P_NonMngdPurchasingSpend3
Non Managed Spend
P_NonMngdPurchasingSpend3 is a Consumption CDS View that provides data about "Non Managed Spend" in SAP S/4HANA. It reads from 2 data sources (I_OperationalAcctgDocItem, P_NonMngdPurchasingSpend2) and exposes 21 fields with key fields AccountingDocument, FiscalYear, CompanyCode, Creditor, GLAccount.
Data Sources (2)
| Source | Alias | Join Type |
|---|---|---|
| I_OperationalAcctgDocItem | _AcctAssgmt | inner |
| P_NonMngdPurchasingSpend2 | P_NonMngdPurchasingSpend2 | from |
Parameters (3)
| Name | Type | Default |
|---|---|---|
| P_DisplayCurrency | displaycurrency | |
| P_StartDate | budat | |
| P_EndDate | budat |
Annotations (7)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PMMNONMNGDPURS3 | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| EndUserText.label | Non Managed Spend | view | |
| VDM.viewType | #CONSUMPTION | view | |
| VDM.private | true | view | |
| AccessControl.personalData.blocking | #NOT_REQUIRED | view |
Fields (21)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | AccountingDocument | Supplier | AccountingDocument | |
| KEY | FiscalYear | Supplier | FiscalYear | |
| KEY | CompanyCode | Supplier | CompanyCode | |
| KEY | Creditor | Supplier | Creditor | |
| KEY | GLAccount | I_OperationalAcctgDocItem | GLAccount | |
| AccountingDocumentType | ||||
| PostingDate | I_OperationalAcctgDocItem | PostingDate | ||
| Material | I_OperationalAcctgDocItem | Material | ||
| ProfitCenter | I_OperationalAcctgDocItem | ProfitCenter | ||
| CostCenter | I_OperationalAcctgDocItem | CostCenter | ||
| AccountingDocCreatedByUser | ||||
| ControllingArea | I_OperationalAcctgDocItem | ControllingArea | ||
| WBSElement | ||||
| WBSElementInternalID | I_OperationalAcctgDocItem | WBSElementInternalID | ||
| Fund | I_OperationalAcctgDocItem | Fund | ||
| Plant | I_OperationalAcctgDocItem | Plant | ||
| PurchaseOrder | I_OperationalAcctgDocItem | PurchasingDocument | ||
| CompanyCodeCurrency | I_OperationalAcctgDocItem | CompanyCodeCurrency | ||
| SupplierAmount | Supplier | SupplierAmount | ||
| CostCenterAmount | I_OperationalAcctgDocItem | AmountInCompanyCodeCurrency | ||
| CostCenterAmount1 | Supplier | CostCenterAmount1 |
@AbapCatalog.sqlViewName: 'PMMNONMNGDPURS3'
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #NOT_REQUIRED
@EndUserText.label: 'Non Managed Spend'
@VDM.viewType: #CONSUMPTION
@VDM.private: true
@AccessControl.personalData.blocking: #NOT_REQUIRED
define view P_NonMngdPurchasingSpend3 // 2749901
with parameters
P_DisplayCurrency : displaycurrency,
P_StartDate : budat,
P_EndDate : budat
as select from P_NonMngdPurchasingSpend2( P_DisplayCurrency:$parameters.P_DisplayCurrency , P_StartDate: $parameters.P_StartDate,
P_EndDate: $parameters.P_EndDate) as Supplier
inner join I_OperationalAcctgDocItem as _AcctAssgmt on ( Supplier.CompanyCode = _AcctAssgmt.CompanyCode
and Supplier.AccountingDocument = _AcctAssgmt.AccountingDocument
and Supplier.FiscalYear = _AcctAssgmt.FiscalYear
and _AcctAssgmt.IsSalesRelated = ''
and _AcctAssgmt.TaxType = ''
and _AcctAssgmt.PostingDate >= $parameters.P_StartDate
and _AcctAssgmt.PostingDate <= $parameters.P_EndDate
and (
( Supplier.SupplierAmount > 0
and _AcctAssgmt.AmountInCompanyCodeCurrency < 0 )
or ( Supplier.SupplierAmount < 0
and _AcctAssgmt.AmountInCompanyCodeCurrency > 0 )
))
and _AcctAssgmt.FinancialAccountType <> 'K' // 3001120
and _AcctAssgmt.FinancialAccountType <> 'D' // 3001120
{
key Supplier.AccountingDocument,
key Supplier.FiscalYear,
key Supplier.CompanyCode,
key Supplier.Creditor ,
key _AcctAssgmt.GLAccount as GLAccount,
cast( Supplier.AccountingDocumentType as mm_a_farp_blart) as AccountingDocumentType, // 3119821
_AcctAssgmt.PostingDate as PostingDate,
_AcctAssgmt.Material as Material,
_AcctAssgmt.ProfitCenter,
_AcctAssgmt.CostCenter,
cast(_AcctAssgmt._JournalEntry.AccountingDocCreatedByUser as ernam ) as AccountingDocCreatedByUser,
_AcctAssgmt.ControllingArea,
cast( _AcctAssgmt.WBSElementInternalID as ps_posnr ) as WBSElement,
_AcctAssgmt.WBSElementInternalID,
_AcctAssgmt.Fund,
_AcctAssgmt.Plant as Plant,
_AcctAssgmt.PurchasingDocument as PurchaseOrder,
_AcctAssgmt.CompanyCodeCurrency,
Supplier.SupplierAmount ,
_AcctAssgmt.AmountInCompanyCodeCurrency as CostCenterAmount, // 3026005
Supplier.CostCenterAmount1
}
group by
Supplier.AccountingDocument,
_AcctAssgmt.GLAccount,
_AcctAssgmt.AccountingDocumentItem,
Supplier.FiscalYear,
Supplier.CompanyCode,
Supplier.Creditor,
Supplier.PostingDate,
Supplier.CompanyCodeCurrency,
Supplier.SupplierAmount,
Supplier.CostCenterAmount1,
Supplier.AccountingDocumentType,
_AcctAssgmt.PostingDate,
_AcctAssgmt.GLAccount,
_AcctAssgmt.ProfitCenter,
_AcctAssgmt.CostCenter,
_AcctAssgmt.Material,
_AcctAssgmt._JournalEntry.AccountingDocCreatedByUser,
_AcctAssgmt.ControllingArea,
_AcctAssgmt.AmountInCompanyCodeCurrency,
_AcctAssgmt.WBSElementInternalID,
_AcctAssgmt.Fund,
_AcctAssgmt.Plant,
_AcctAssgmt.CompanyCodeCurrency,
_AcctAssgmt.PurchasingDocument
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_JOURNALENTRY",
"I_OPERATIONALACCTGDOCITEM",
"P_NONMNGDPURCHASINGSPEND2"
],
"ASSOCIATED":
[],
"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