P_PT_BOPCustSuplrBalance

DDL: P_PT_BOPCUSTSUPLRBALANCE Type: view_entity COMPOSITE

P_PT_BOPCustSuplrBalance is a Composite CDS View in SAP S/4HANA. It reads from 2 data sources (I_PT_BOPEndOfPeriodGLAccount, I_OperationalAcctgDocItem) and exposes 39 fields with key fields CompanyCode, AccountingDocument, FiscalYear, AccountingDocumentItem.

Data Sources (2)

SourceAliasJoin Type
I_PT_BOPEndOfPeriodGLAccount CONFIG inner
I_OperationalAcctgDocItem Item from

Annotations (7)

NameValueLevelField
AccessControl.authorizationCheck #NOT_REQUIRED view
Metadata.ignorePropagatedAnnotations true view
VDM.private true view
VDM.viewType #COMPOSITE view
ObjectModel.usageType.serviceQuality #X view
ObjectModel.usageType.sizeCategory #S view
ObjectModel.usageType.dataClass #MIXED view

Fields (39)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode I_OperationalAcctgDocItem CompanyCode Receiver Company Code
KEY AccountingDocument I_OperationalAcctgDocItem AccountingDocument Journal Entry
KEY FiscalYear I_OperationalAcctgDocItem FiscalYear G/L Fiscal Year
KEY AccountingDocumentItem I_OperationalAcctgDocItem AccountingDocumentItem Posting View Item
ClearingAccountingDocument I_OperationalAcctgDocItem ClearingAccountingDocument Clearing Journal Entry
ClearingJournalEntry I_OperationalAcctgDocItem ClearingJournalEntry Clrng doc.
ClearingDate I_OperationalAcctgDocItem ClearingDate Clearing Date
Postingdate I_OperationalAcctgDocItem PostingDate Posting Date for GR
FinancialAccountType I_OperationalAcctgDocItem FinancialAccountType Fin. Account Type
GLAccount I_OperationalAcctgDocItem GLAccount General Ledger
Customer I_OperationalAcctgDocItem Customer Sold-to Party
Supplier I_OperationalAcctgDocItem Supplier Supplier
BusinessPartnerelseendasBusinessPartner
PT_BOPValueType
PT_BOPAccountType
DebitCreditCode I_OperationalAcctgDocItem DebitCreditCode Single-Character Flag
AmountInTransactionCurrency I_OperationalAcctgDocItem AmountInTransactionCurrency Pt Crcy Amt
TransactionCurrency I_OperationalAcctgDocItem TransactionCurrency Transaction Currency
CurrencyISOCode
LowerBoundaryAccount I_PT_BOPEndOfPeriodGLAccount LowerBoundaryAccount From Account Number
UpperBoundaryAccount I_PT_BOPEndOfPeriodGLAccount UpperBoundaryAccount Up to Account No.
PT_BOPAcctBalDebitClsfctn I_PT_BOPEndOfPeriodGLAccount PT_BOPAcctBalDebitClsfctn Class. Code (Debit)
PT_BOPAcctBalCreditClsfctn I_PT_BOPEndOfPeriodGLAccount PT_BOPAcctBalCreditClsfctn Class. Code (Credit)
AccountingDocumentCategory I_OperationalAcctgDocItem AccountingDocumentCategory Journal Entry Category
ClearingDocFiscalYear I_OperationalAcctgDocItem ClearingDocFiscalYear Fiscal Year of Clearing Journal Entry
AccountingDocumentType I_OperationalAcctgDocItem AccountingDocumentType Journal Entry Type
SpecialGLCode I_OperationalAcctgDocItem SpecialGLCode Special G/L Ind
PostingKey I_OperationalAcctgDocItem PostingKey Posting Key
DocumentDate I_OperationalAcctgDocItem DocumentDate Journal Entry Date
FinancialTransactionType I_OperationalAcctgDocItem FinancialTransactionType Transact. Type
SupplierVATRegistration
CustomerVATRegistration
SupplierVATRegistrationCountry
CustomerVATRegistrationCountry
SupplierCountry
CustomerCountry
OneTimeVendor
OneTimeCustomer
OneTimeCountry

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_PT_BOPCustSuplrBalance.
-- 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 P_PT_BOPCustSuplrBalance AS
SELECT
  Item.CompanyCode AS CompanyCode,
  Item.AccountingDocument AS AccountingDocument,
  Item.FiscalYear AS FiscalYear,
  Item.AccountingDocumentItem AS AccountingDocumentItem,
  Item.ClearingAccountingDocument AS ClearingAccountingDocument,
  Item.ClearingJournalEntry AS ClearingJournalEntry,
  Item.ClearingDate AS ClearingDate,
  Item.PostingDate AS Postingdate,
  Item.FinancialAccountType AS FinancialAccountType,
  Item.GLAccount AS GLAccount,
  Item.Customer AS Customer,
  Item.Supplier AS Supplier,
  case when Item.FinancialAccountType = 'K' then Item._Supplier._SupplierToBusinessPartner._BusinessPartner.BusinessPartner when Item.FinancialAccountType = 'D' then Item._Customer._CustomerToBusinessPartner._BusinessPartner.BusinessPartner else '' end as BusinessPartner AS BusinessPartnerelseendasBusinessPartner,
  cast( 'P' as fipt_cope_value_type ) AS PT_BOPValueType,
  cast( 'X' as fipt_cope_acctype ) AS PT_BOPAccountType,
  Item.DebitCreditCode AS DebitCreditCode,
  Item.AmountInTransactionCurrency AS AmountInTransactionCurrency,
  Item.TransactionCurrency AS TransactionCurrency,
  Item._TransactionCurrency.CurrencyISOCode AS CurrencyISOCode,
  CONFIG.LowerBoundaryAccount AS LowerBoundaryAccount,
  CONFIG.UpperBoundaryAccount AS UpperBoundaryAccount,
  CONFIG.PT_BOPAcctBalDebitClsfctn AS PT_BOPAcctBalDebitClsfctn,
  CONFIG.PT_BOPAcctBalCreditClsfctn AS PT_BOPAcctBalCreditClsfctn,
  Item.AccountingDocumentCategory AS AccountingDocumentCategory,
  Item.ClearingDocFiscalYear AS ClearingDocFiscalYear,
  Item.AccountingDocumentType AS AccountingDocumentType,
  Item.SpecialGLCode AS SpecialGLCode,
  Item.PostingKey AS PostingKey,
  Item.DocumentDate AS DocumentDate,
  Item.FinancialTransactionType AS FinancialTransactionType,
  Item._Supplier.VATRegistration AS SupplierVATRegistration,
  Item._Customer.VATRegistration AS CustomerVATRegistration,
  left(Item._Supplier.VATRegistration ,2) AS SupplierVATRegistrationCountry,
  left(Item._Customer.VATRegistration,2) AS CustomerVATRegistrationCountry,
  Item._Supplier.Country AS SupplierCountry,
  Item._Customer.Country AS CustomerCountry,
  Item._Supplier.IsOneTimeAccount AS OneTimeVendor,
  Item._Customer.IsOneTimeAccount AS OneTimeCustomer,
  Item._OneTimeAccountBP.Country AS OneTimeCountry
FROM I_OperationalAcctgDocItem AS Item
INNER JOIN I_PT_BOPEndOfPeriodGLAccount AS CONFIG ON /* join condition not captured in parsed metadata */
;