R_CollectionsInvoiceTP
Collections Invoices
R_CollectionsInvoiceTP is a Transactional CDS View that provides data about "Collections Invoices" in SAP S/4HANA. It reads from 1 data source (I_CollectionsInvoice) and exposes 73 fields with key fields CollectionSegment, CompanyCode, FiscalYear, AccountingDocument, AccountingDocumentItem. It has 7 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_CollectionsInvoice | I_CollectionsInvoice | from |
Associations (7)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..*] | I_CollectionsInvoiceNote | _CollectionsInvoiceNote | $projection.CompanyCode = _CollectionsInvoiceNote.CompanyCode and $projection.AccountingDocument = _CollectionsInvoiceNote.AccountingDocument and $projection.FiscalYear = _CollectionsInvoiceNote.FiscalYear and $projection.AccountingDocumentItem = _CollectionsInvoiceNote.AccountingDocumentItem |
| [0..1] | I_OperationalAcctgDocItem | _OperationalAcctgDocItem | $projection.CompanyCode = _OperationalAcctgDocItem.CompanyCode and $projection.FiscalYear = _OperationalAcctgDocItem.FiscalYear and $projection.AccountingDocument = _OperationalAcctgDocItem.AccountingDocument and $projection.AccountingDocumentItem = _OperationalAcctgDocItem.AccountingDocumentItem |
| [0..*] | I_CollsInvoiceRelatedDsputCase | _LinkedDisputeCase | $projection.CompanyCode = _LinkedDisputeCase.CompanyCode and $projection.AccountingDocument = _LinkedDisputeCase.AccountingDocument and $projection.FiscalYear = _LinkedDisputeCase.FiscalYear and $projection.AccountingDocumentItem = _LinkedDisputeCase.AccountingDocumentItem |
| [0..*] | I_CollsInvoiceRelatedPrms2P | _LinkedPromiseToPay | $projection.CompanyCode = _LinkedPromiseToPay.CompanyCode and $projection.AccountingDocument = _LinkedPromiseToPay.AccountingDocument and $projection.FiscalYear = _LinkedPromiseToPay.FiscalYear and $projection.AccountingDocumentItem = _LinkedPromiseToPay.AccountingDocumentItem |
| [0..*] | I_CollsInvoiceRelatedResubmsn | _LinkedResubmission | $projection.CompanyCode = _LinkedResubmission.CompanyCode and $projection.AccountingDocument = _LinkedResubmission.AccountingDocument and $projection.FiscalYear = _LinkedResubmission.FiscalYear and $projection.AccountingDocumentItem = _LinkedResubmission.AccountingDocumentItem |
| [0..1] | I_CollsInvcPaytDelayPrediction | _CollsInvcPaytDelayPrediction | $projection.CompanyCode = _CollsInvcPaytDelayPrediction.CompanyCode and $projection.AccountingDocument = _CollsInvcPaytDelayPrediction.AccountingDocument and $projection.FiscalYear = _CollsInvcPaytDelayPrediction.FiscalYear and $projection.AccountingDocumentItem = _CollsInvcPaytDelayPrediction.AccountingDocumentItem |
| [1] | E_CollectionsInvoice | _Extension | $projection.CollectionSegment = _Extension.CollectionSegment and $projection.CompanyCode = _Extension.CompanyCode and $projection.AccountingDocument = _Extension.AccountingDocument and $projection.FiscalYear = _Extension.FiscalYear and $projection.AccountingDocumentItem = _Extension.AccountingDocumentItem |
Annotations (10)
| Name | Value | Level | Field |
|---|---|---|---|
| AccessControl.authorizationCheck | #CHECK | view | |
| AccessControl.personalData.blocking | #BLOCKED_DATA_EXCLUDED | view | |
| EndUserText.label | Collections Invoices | view | |
| VDM.viewType | #TRANSACTIONAL | view | |
| VDM.lifecycle.contract.type | #SAP_INTERNAL_API | view | |
| ObjectModel.usageType.serviceQuality | #X | view | |
| ObjectModel.usageType.sizeCategory | #L | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| ObjectModel.representativeKey | AccountingDocument | view | |
| ObjectModel.sapObjectNodeType.name | JournalEntry | view |
Fields (73)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CollectionSegment | CollectionSegment | Segment | |
| KEY | CompanyCode | CompanyCode | Receiver Company Code | |
| KEY | FiscalYear | FiscalYear | G/L Fiscal Year | |
| KEY | AccountingDocument | AccountingDocument | Journal Entry | |
| KEY | AccountingDocumentItem | AccountingDocumentItem | Posting View Item | |
| Customer | Customer | Sold-to Party | ||
| BranchAccount | BranchAccount | Branch Account No. | ||
| DocumentDate | DocumentDate | Journal Entry Date | ||
| PostingDate | PostingDate | Posting Date for GR | ||
| DunningLevel | DunningLevel | Dunning Level | ||
| LastDunningDate | LastDunningDate | Last Dunned | ||
| NetDueDate | NetDueDate | Net Due Date | ||
| Reference1InDocumentHeader | Reference1InDocumentHeader | Reference 1 | ||
| Reference2InDocumentHeader | Reference2InDocumentHeader | Reference 2 | ||
| PaymentMethod | PaymentMethod | Pymt Meth. | ||
| FinancialAccountType | FinancialAccountType | Fin. Account Type | ||
| OverdueDays | ||||
| CashDiscount1Days | Days from Baseline Date for Payment | |||
| AmountInTransactionCurrency | AmountInTransactionCurrency | Pt Crcy Amt | ||
| PaidAmount | PaidAmount | Paid Amount | ||
| DunnedAmount | DunnedAmount | |||
| OpenAmountInDocumentCurrency | OpenAmountInDocumentCurrency | |||
| CashDiscountAmtInTransacCrcy | ||||
| TransactionCurrency | TransactionCurrency | Transaction Currency | ||
| PaymentDate | PaymentDate | Payment Date | ||
| DunningBlockingReason | DunningBlockingReason | Set Dunning Block | ||
| SpecialGLCode | SpecialGLCode | Special G/L Ind | ||
| OperationalGLAccount | Operational G/L Acct | |||
| FiscalPeriod | FiscalPeriod | Tax period | ||
| BillingDocument | BillingDocument | SD Document | ||
| PostingKey | PostingKey | Posting Key | ||
| DocumentItemText | DocumentItemText | Text | ||
| ReferenceDocumentLogicalSystem | ReferenceDocumentLogicalSystem | Ref. Doc. Lgcl Syst. | ||
| LastDunningDurationInDays | LastDunningDurationInDays | |||
| CaseStatus | CaseStatus | Status | ||
| CaseStatusName | CaseStatusName | |||
| CaseReason | CaseReason | Reason | ||
| ReasonCodeName | ReasonCodeName | |||
| PromiseToPayStatus | PromiseToPayStatus | State | ||
| DisputeCase | DisputeCase | Case ID | ||
| PromiseToPay | PromiseToPay | |||
| NumberOfResubmissions | NumberOfResubmissions | |||
| NumberOfDaysSinceResubmission | NumberOfDaysSinceResubmission | |||
| ArrangedAmount | ArrangedAmount | |||
| PromisedAmount | PromisedAmount | Promised Amount | ||
| PromiseToPayLevel | Level | |||
| PromiseToPayDueDate | PromiseToPayDueDate | |||
| DisputedAmount | DisputedAmount | Disputed Amount | ||
| CreditedAmount | CreditedAmount | Credited | ||
| DocumentReferenceID | DocumentReferenceID | Reference | ||
| ObjectKey | ObjectKey | Object Key | ||
| Country | Country | Venue: Ctry/Reg | ||
| ResubmissionUUID | ResubmissionUUID | Resubmission Key | ||
| ResubmissionDueDate | ResubmissionDueDate | Resubmission Date | ||
| ResubmissionReason | ResubmissionReason | Reason | ||
| CaseUniqueID | CaseUniqueID | |||
| LatePaymentRisk | LatePaymentRisk | |||
| _CollectionSegment | _CollectionSegment | |||
| _CompanyCode | _CompanyCode | |||
| _Customer | _Customer | |||
| _BranchAccount | _BranchAccount | |||
| _BillingDocument | _BillingDocument | |||
| _DunningBlockingReasonCode | _DunningBlockingReasonCode | |||
| _SpecialGLCode | _SpecialGLCode | |||
| _PostingKey | _PostingKey | |||
| _PromiseToPayStatus | _PromiseToPayStatus | |||
| _LinkedDisputeCase | _LinkedDisputeCase | |||
| _LinkedResubmission | _LinkedResubmission | |||
| _LinkedPromiseToPay | _LinkedPromiseToPay | |||
| _CollectionsInvoiceNote | _CollectionsInvoiceNote | |||
| _PaymentMethod | _PaymentMethod | |||
| _OperationalAcctgDocItem | _OperationalAcctgDocItem | |||
| _CollsInvcPaytDelayPrediction | _CollsInvcPaytDelayPrediction |
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 R_CollectionsInvoiceTP.
-- 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.
CREATE VIEW R_CollectionsInvoiceTP AS
SELECT
CollectionSegment,
CompanyCode,
FiscalYear,
AccountingDocument,
AccountingDocumentItem,
Customer,
BranchAccount,
DocumentDate,
PostingDate,
DunningLevel,
LastDunningDate,
NetDueDate,
Reference1InDocumentHeader,
Reference2InDocumentHeader,
PaymentMethod,
FinancialAccountType,
cast ( OverdueDays as coll_pr_days_in_arrears ) AS OverdueDays,
cast ( CashDiscount1Days as coll_pr_due_for_cashdisc_1 preserving type ) AS CashDiscount1Days,
AmountInTransactionCurrency,
PaidAmount,
DunnedAmount,
OpenAmountInDocumentCurrency,
cast ( CashDiscountAmtInTransacCrcy as coll_pr_cash_discount_amt ) AS CashDiscountAmtInTransacCrcy,
TransactionCurrency,
PaymentDate,
DunningBlockingReason,
SpecialGLCode,
cast( OperationalGLAccount as coll_pr_gl_account preserving type ) AS OperationalGLAccount,
FiscalPeriod,
BillingDocument,
PostingKey,
DocumentItemText,
ReferenceDocumentLogicalSystem,
LastDunningDurationInDays,
CaseStatus,
CaseStatusName,
CaseReason,
ReasonCodeName,
PromiseToPayStatus,
DisputeCase,
PromiseToPay,
NumberOfResubmissions,
NumberOfDaysSinceResubmission,
ArrangedAmount,
PromisedAmount,
cast( PromiseToPayLevel as coll_pr_p2p_level ) AS PromiseToPayLevel,
PromiseToPayDueDate,
DisputedAmount,
CreditedAmount,
DocumentReferenceID,
ObjectKey,
Country,
ResubmissionUUID,
ResubmissionDueDate,
ResubmissionReason,
CaseUniqueID,
LatePaymentRisk
FROM I_CollectionsInvoice
LEFT OUTER JOIN I_CollectionsInvoiceNote AS _CollectionsInvoiceNote ON CompanyCode = _CollectionsInvoiceNote.CompanyCode AND AccountingDocument = _CollectionsInvoiceNote.AccountingDocument AND FiscalYear = _CollectionsInvoiceNote.FiscalYear AND AccountingDocumentItem = _CollectionsInvoiceNote.AccountingDocumentItem -- association [0..*]
LEFT OUTER JOIN I_OperationalAcctgDocItem AS _OperationalAcctgDocItem ON CompanyCode = _OperationalAcctgDocItem.CompanyCode AND FiscalYear = _OperationalAcctgDocItem.FiscalYear AND AccountingDocument = _OperationalAcctgDocItem.AccountingDocument AND AccountingDocumentItem = _OperationalAcctgDocItem.AccountingDocumentItem -- association [0..1]
LEFT OUTER JOIN I_CollsInvoiceRelatedDsputCase AS _LinkedDisputeCase ON CompanyCode = _LinkedDisputeCase.CompanyCode AND AccountingDocument = _LinkedDisputeCase.AccountingDocument AND FiscalYear = _LinkedDisputeCase.FiscalYear AND AccountingDocumentItem = _LinkedDisputeCase.AccountingDocumentItem -- association [0..*]
LEFT OUTER JOIN I_CollsInvoiceRelatedPrms2P AS _LinkedPromiseToPay ON CompanyCode = _LinkedPromiseToPay.CompanyCode AND AccountingDocument = _LinkedPromiseToPay.AccountingDocument AND FiscalYear = _LinkedPromiseToPay.FiscalYear AND AccountingDocumentItem = _LinkedPromiseToPay.AccountingDocumentItem -- association [0..*]
LEFT OUTER JOIN I_CollsInvoiceRelatedResubmsn AS _LinkedResubmission ON CompanyCode = _LinkedResubmission.CompanyCode AND AccountingDocument = _LinkedResubmission.AccountingDocument AND FiscalYear = _LinkedResubmission.FiscalYear AND AccountingDocumentItem = _LinkedResubmission.AccountingDocumentItem -- association [0..*]
LEFT OUTER JOIN I_CollsInvcPaytDelayPrediction AS _CollsInvcPaytDelayPrediction ON CompanyCode = _CollsInvcPaytDelayPrediction.CompanyCode AND AccountingDocument = _CollsInvcPaytDelayPrediction.AccountingDocument AND FiscalYear = _CollsInvcPaytDelayPrediction.FiscalYear AND AccountingDocumentItem = _CollsInvcPaytDelayPrediction.AccountingDocumentItem -- association [0..1]
LEFT OUTER JOIN E_CollectionsInvoice AS _Extension ON CollectionSegment = _Extension.CollectionSegment AND CompanyCode = _Extension.CompanyCode AND AccountingDocument = _Extension.AccountingDocument AND FiscalYear = _Extension.FiscalYear AND AccountingDocumentItem = _Extension.AccountingDocumentItem -- association [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