P_StRpSalesInvoiceItem
Private View for Sales Invoice List
P_StRpSalesInvoiceItem is a Consumption CDS View that provides data about "Private View for Sales Invoice List" in SAP S/4HANA. It reads from 7 data sources and exposes 20 fields with key fields CompanyCode, BillingDocument, BillingDocumentItem, FiscalYear, StatryRptCategory. It has 2 associations to related views.
Data Sources (7)
| Source | Alias | Join Type |
|---|---|---|
| I_BillingDocumentBasic | I_BillingDocumentBasic | inner |
| I_BillingDocumentItemBasic | I_BillingDocumentItemBasic | from |
| I_Customer | I_Customer | inner |
| I_DeliveryDocument | I_DeliveryDocument | left_outer |
| I_DeliveryDocumentItem | I_DeliveryDocumentItem | left_outer |
| I_JournalEntry | I_JournalEntry | inner |
| P_PlantsAndBranchesItem | P_PlantsAndBranchesItem | left_outer |
Associations (2)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..*] | I_StRpJournalEntryLog | _ReportedItemsLog | _ReportedItemsLog.CompanyCode = $projection.CompanyCode and _ReportedItemsLog.AccountingDocument = $projection.AccountingDocument and _ReportedItemsLog.FiscalYear = $projection.FiscalYear |
| [1..1] | I_UnitOfMeasureText | _UnitofMeasure | _UnitofMeasure.UnitOfMeasure = I_BillingDocumentItemBasic.BillingQuantityUnit and _UnitofMeasure.Language = $session.system_language |
Annotations (12)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PSALEINVLITEM | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| EndUserText.label | Private View for Sales Invoice List | view | |
| VDM.viewType | #CONSUMPTION | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| ObjectModel.usageType.serviceQuality | #P | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| AccessControl.personalData.blocking | #NOT_REQUIRED | view | |
| VDM.private | true | view | |
| AccessControl.blocking | #BLOCKED_DATA_INCLUDED | view |
Fields (20)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CompanyCode | I_BillingDocumentBasic | CompanyCode | Receiver Company Code |
| KEY | BillingDocument | I_BillingDocumentBasic | BillingDocument | SD Document |
| KEY | BillingDocumentItem | I_BillingDocumentItemBasic | BillingDocumentItem | Item |
| KEY | FiscalYear | I_BillingDocumentBasic | FiscalYear | G/L Fiscal Year |
| KEY | StatryRptCategory | _ReportedItemsLog | StatryRptCategory | Report ID |
| KEY | StatryRptgEntity | _ReportedItemsLog | StatryRptgEntity | Reporting Entity |
| KEY | StatryRptRunID | _ReportedItemsLog | StatryRptRunID | Report Run ID |
| AccountingDocument | I_JournalEntry | AccountingDocument | Journal Entry | |
| PayerParty | I_BillingDocumentBasic | PayerParty | Payer | |
| DocumentReferenceID | I_BillingDocumentBasic | DocumentReferenceID | Reference | |
| Material | I_BillingDocumentItemBasic | Material | Vehicle Model | |
| Plant | I_DeliveryDocumentItem | Plant | Valuation Area | |
| Country | P_PlantsAndBranchesItem | Country | Venue: Ctry/Reg | |
| BillingDocumentDate | I_BillingDocumentBasic | BillingDocumentDate | Billing Date | |
| MeterReadingSystemDate | ||||
| BillingQuantityUnit | I_BillingDocumentItemBasic | BillingQuantityUnit | Sales Unit | |
| Quantity | I_BillingDocumentItemBasic | BillingQuantity | Invoiced Qty | |
| CustomerName | I_Customer | CustomerName | Name of Customer | |
| CustomerCountry | I_Customer | Country | Venue: Ctry/Reg | |
| _UnitofMeasure | _UnitofMeasure |
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_StRpSalesInvoiceItem.
-- 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: PSALEINVLITEM
CREATE VIEW P_StRpSalesInvoiceItem AS
SELECT
I_BillingDocumentBasic.CompanyCode AS CompanyCode,
I_BillingDocumentBasic.BillingDocument AS BillingDocument,
I_BillingDocumentItemBasic.BillingDocumentItem AS BillingDocumentItem,
I_BillingDocumentBasic.FiscalYear AS FiscalYear,
_ReportedItemsLog.StatryRptCategory AS StatryRptCategory,
_ReportedItemsLog.StatryRptgEntity AS StatryRptgEntity,
_ReportedItemsLog.StatryRptRunID AS StatryRptRunID,
I_JournalEntry.AccountingDocument AS AccountingDocument,
I_BillingDocumentBasic.PayerParty AS PayerParty,
I_BillingDocumentBasic.DocumentReferenceID AS DocumentReferenceID,
I_BillingDocumentItemBasic.Material AS Material,
I_DeliveryDocumentItem.Plant AS Plant,
P_PlantsAndBranchesItem.Country AS Country,
I_BillingDocumentBasic.BillingDocumentDate AS BillingDocumentDate,
$session.system_date AS MeterReadingSystemDate,
I_BillingDocumentItemBasic.BillingQuantityUnit AS BillingQuantityUnit,
I_BillingDocumentItemBasic.BillingQuantity AS Quantity,
I_Customer.CustomerName AS CustomerName,
I_Customer.Country AS CustomerCountry
FROM I_BillingDocumentItemBasic
INNER JOIN I_BillingDocumentBasic ON /* join condition not captured in parsed metadata */
INNER JOIN I_JournalEntry ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_DeliveryDocument ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_DeliveryDocumentItem ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN P_PlantsAndBranchesItem ON /* join condition not captured in parsed metadata */
INNER JOIN I_Customer ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_StRpJournalEntryLog AS _ReportedItemsLog ON _ReportedItemsLog.CompanyCode = CompanyCode AND _ReportedItemsLog.AccountingDocument = AccountingDocument AND _ReportedItemsLog.FiscalYear = FiscalYear -- association [0..*]
LEFT OUTER JOIN I_UnitOfMeasureText AS _UnitofMeasure ON _UnitofMeasure.UnitOfMeasure = I_BillingDocumentItemBasic.BillingQuantityUnit AND _UnitofMeasure.Language = $session.system_language -- 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