P_APInvoiceProcessingAnalysis1
P_APInvoiceProcessingAnalysis1 is a Composite CDS View in SAP S/4HANA. It reads from 1 data source (I_ReceivablesPayablesItem) and exposes 13 fields with key fields CompanyCode, AccountingDocument, AccountingDocumentItem, FiscalYear. It has 1 association to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_ReceivablesPayablesItem | I_ReceivablesPayablesItem | from |
Parameters (2)
| Name | Type | Default |
|---|---|---|
| P_KeyDate | abap.dats | |
| P_StartDate | vdm_v_start_date |
Associations (1)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_AccountingDocument | _AccountingDocument | I_ReceivablesPayablesItem.AccountingDocument = _AccountingDocument.AccountingDocument and I_ReceivablesPayablesItem.CompanyCode = _AccountingDocument.CompanyCode and I_ReceivablesPayablesItem.FiscalYear = _AccountingDocument.FiscalYear |
Annotations (6)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PFIAPINVPROALY1 | view | |
| VDM.private | true | view | |
| VDM.viewType | #COMPOSITE | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| Metadata.ignorePropagatedAnnotations | true | view |
Fields (13)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CompanyCode | I_ReceivablesPayablesItem | CompanyCode | |
| KEY | AccountingDocument | I_ReceivablesPayablesItem | AccountingDocument | |
| KEY | AccountingDocumentItem | I_ReceivablesPayablesItem | AccountingDocumentItem | |
| KEY | FiscalYear | I_ReceivablesPayablesItem | FiscalYear | |
| Supplier | I_ReceivablesPayablesItem | Creditor | ||
| PaymentBlockingReason | I_ReceivablesPayablesItem | PaymentBlockingReason | ||
| AccountingDocumentCategory | I_ReceivablesPayablesItem | AccountingDocumentCategory | ||
| AccountingDocCreatedByUser | _AccountingDocument | AccountingDocCreatedByUser | ||
| CompanyCodeCurrency | I_ReceivablesPayablesItem | CompanyCodeCurrency | ||
| PostingDate | I_ReceivablesPayablesItem | PostingDate | ||
| ClearingDate | I_ReceivablesPayablesItem | ClearingDate | ||
| AmountInCompanyCodeCurrency | ||||
| NumberOfItems |
@AbapCatalog.sqlViewName: 'PFIAPINVPROALY1'
@VDM.private: true
@VDM.viewType: #COMPOSITE
@AccessControl.authorizationCheck: #NOT_REQUIRED
@ClientHandling.algorithm: #SESSION_VARIABLE
@Metadata.ignorePropagatedAnnotations: true
define view P_APInvoiceProcessingAnalysis1
with parameters
P_KeyDate : abap.dats,
P_StartDate : vdm_v_start_date
as select from I_ReceivablesPayablesItem
association [0..1] to I_AccountingDocument as _AccountingDocument
on I_ReceivablesPayablesItem.AccountingDocument = _AccountingDocument.AccountingDocument
and I_ReceivablesPayablesItem.CompanyCode = _AccountingDocument.CompanyCode
and I_ReceivablesPayablesItem.FiscalYear = _AccountingDocument.FiscalYear
{
key I_ReceivablesPayablesItem.CompanyCode,
key I_ReceivablesPayablesItem.AccountingDocument,
key I_ReceivablesPayablesItem.AccountingDocumentItem,
key I_ReceivablesPayablesItem.FiscalYear,
I_ReceivablesPayablesItem.Creditor as Supplier,
I_ReceivablesPayablesItem.PaymentBlockingReason,
I_ReceivablesPayablesItem.AccountingDocumentCategory,
_AccountingDocument.AccountingDocCreatedByUser,
I_ReceivablesPayablesItem.CompanyCodeCurrency,
I_ReceivablesPayablesItem.PostingDate,
I_ReceivablesPayablesItem.ClearingDate,
cast(-I_ReceivablesPayablesItem.AmountInCompanyCodeCurrency as dmshb_farp) as AmountInCompanyCodeCurrency,//Negative sign for AP amount display
cast( 1 as abap.int4 ) as NumberOfItems
}
where I_ReceivablesPayablesItem.AccountingDocumentCategory = ''
and I_ReceivablesPayablesItem.FinancialAccountType = 'K'
and I_ReceivablesPayablesItem.IsSalesRelated = 'X'
and I_ReceivablesPayablesItem.SpecialGLCode = ''
and I_ReceivablesPayablesItem.PostingDate >= :P_StartDate
and I_ReceivablesPayablesItem.PostingDate <= :P_KeyDate;
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_ACCOUNTINGDOCUMENT",
"I_RECEIVABLESPAYABLESITEM"
],
"ASSOCIATED":
[
"I_ACCOUNTINGDOCUMENT"
],
"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