P_PrepaymentReferenceDocument

DDL: P_PREPAYMENTREFERENCEDOCUMENT SQL: P_REFDOC Type: view BASIC

P_PrepaymentReferenceDocument is a Basic CDS View in SAP S/4HANA. It reads from 1 data source (I_PrepaymentAssignedDocument) and exposes 23 fields with key field PrepaymentAssignedDocumentUUID.

Data Sources (1)

SourceAliasJoin Type
I_PrepaymentAssignedDocument ConsumptionDocument from

Annotations (11)

NameValueLevelField
AbapCatalog.sqlViewName P_REFDOC view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
ClientHandling.algorithm #SESSION_VARIABLE view
AccessControl.authorizationCheck #NOT_REQUIRED view
VDM.private true view
VDM.viewType #BASIC view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.serviceQuality #X view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
Metadata.ignorePropagatedAnnotations true view

Fields (23)

KeyFieldSource TableSource FieldDescription
KEY PrepaymentAssignedDocumentUUID I_PrepaymentAssignedDocument PrepaymentAssignedDocumentUUID Key
PrepaymentConsumptionDocUUID I_PrepaymentAssignedDocument PrepaymentConsumptionDocUUID Key
SAPBusinessObjectTypeCode I_PrepaymentAssignedDocument SAPBusinessObjectTypeCode SAP Obj Rep
DocNumber
DocumentItemNumber I_PrepaymentAssignedDocument DocumentItemNumber Item
PrepaymentAgrmtLinkType I_PrepaymentAssignedDocument PrepaymentAgrmtLinkType Link Type
ReferenceApplicationDocument I_PrepaymentAssignedDocument ReferenceApplicationDocument Ref Preceeding Doc
PrepaymentAgreementIsActive I_PrepaymentAssignedDocument PrepaymentAgreementIsActive Active
PrepaymentAgrmtRefLink I_PrepaymentAssignedDocument PrepaymentAgrmtRefLink Reference Link
PrepaymentAgrmtRefLinkUUID I_PrepaymentAssignedDocument PrepaymentAgrmtRefLinkUUID Key
PrepaymentAgrmtRefBusObject I_PrepaymentAssignedDocument PrepaymentAgrmtRefBusObject Business Object Type
PrepaymentAgrmtRefDocItem I_PrepaymentAssignedDocument PrepaymentAgrmtRefDocItem Linking Docu No. Itm
PrepaymentAgrmtRefDocument
PrepaymentAgrmtLinkAmount I_PrepaymentAssignedDocument PrepaymentAgrmtLinkAmount Pre Agrm Amount
PrepaymentAgreementCurrency I_PrepaymentAssignedDocument PrepaymentAgreementCurrency Currency
PrepayAgrmtAccrInterestAmount I_PrepaymentAssignedDocument PrepayAgrmtAccrInterestAmount Accrual Inter. Amt
PrepayAgrmtAccrInterestCrcy I_PrepaymentAssignedDocument PrepayAgrmtAccrInterestCrcy Accrual Inter. Curr
PrepayAgrmtValidFromDateTime I_PrepaymentAssignedDocument PrepayAgrmtValidFromDateTime Valid From Date Time
PrepayAgrmtValidToDateTime I_PrepaymentAssignedDocument PrepayAgrmtValidToDateTime Valid To Date Time
CreatedByUserasCreatedByUser
CreationDateTime I_PrepaymentAssignedDocument CreationDateTime Timestamp
LastChangedByUser I_PrepaymentAssignedDocument LastChangedByUser User Name
LastChangeDateTime I_PrepaymentAssignedDocument LastChangeDateTime Timestamp

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_PrepaymentReferenceDocument.
-- 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: P_REFDOC

CREATE VIEW P_PrepaymentReferenceDocument AS
SELECT
  ConsumptionDocument.PrepaymentAssignedDocumentUUID AS PrepaymentAssignedDocumentUUID,
  ConsumptionDocument.PrepaymentConsumptionDocUUID AS PrepaymentConsumptionDocUUID,
  ConsumptionDocument.SAPBusinessObjectTypeCode AS SAPBusinessObjectTypeCode,
  RIGHT( ConsumptionDocument.DocNumber, 10 ) AS DocNumber,
  ConsumptionDocument.DocumentItemNumber AS DocumentItemNumber,
  ConsumptionDocument.PrepaymentAgrmtLinkType AS PrepaymentAgrmtLinkType,
  ConsumptionDocument.ReferenceApplicationDocument AS ReferenceApplicationDocument,
  ConsumptionDocument.PrepaymentAgreementIsActive AS PrepaymentAgreementIsActive,
  ConsumptionDocument.PrepaymentAgrmtRefLink AS PrepaymentAgrmtRefLink,
  ConsumptionDocument.PrepaymentAgrmtRefLinkUUID AS PrepaymentAgrmtRefLinkUUID,
  ConsumptionDocument.PrepaymentAgrmtRefBusObject AS PrepaymentAgrmtRefBusObject,
  ConsumptionDocument.PrepaymentAgrmtRefDocItem AS PrepaymentAgrmtRefDocItem,
  RIGHT( ConsumptionDocument.PrepaymentAgrmtRefDocument, 10 ) AS PrepaymentAgrmtRefDocument,
  ConsumptionDocument.PrepaymentAgrmtLinkAmount AS PrepaymentAgrmtLinkAmount,
  ConsumptionDocument.PrepaymentAgreementCurrency AS PrepaymentAgreementCurrency,
  ConsumptionDocument.PrepayAgrmtAccrInterestAmount AS PrepayAgrmtAccrInterestAmount,
  ConsumptionDocument.PrepayAgrmtAccrInterestCrcy AS PrepayAgrmtAccrInterestCrcy,
  ConsumptionDocument.PrepayAgrmtValidFromDateTime AS PrepayAgrmtValidFromDateTime,
  ConsumptionDocument.PrepayAgrmtValidToDateTime AS PrepayAgrmtValidToDateTime,
  ConsumptionDocument.CreationDateTime AS CreationDateTime,
  ConsumptionDocument.LastChangedByUser AS LastChangedByUser,
  ConsumptionDocument.LastChangeDateTime AS LastChangeDateTime
FROM I_PrepaymentAssignedDocument AS ConsumptionDocument
;