P_CN_SuplrAcctBal
Supplier Account Balance
P_CN_SuplrAcctBal is a Composite CDS View that provides data about "Supplier Account Balance" in SAP S/4HANA. It reads from 1 data source (P_CN_BPAcctBalTF) and exposes 31 fields with key fields CompanyCode, FiscalYear, FiscalPeriod, FiscalYearPeriod, GLAccount. It has 2 associations to related views. Part of development package GLO_FIN_CN_BAL.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| P_CN_BPAcctBalTF | P_CN_BPAcctBalTF | from |
Parameters (6)
| Name | Type | Default |
|---|---|---|
| P_CompanyCode | bukrs | |
| P_FiscalYear | gjahr | |
| P_CurrencyRole | fac_crcyrole | |
| P_ReportingFiscalPeriod | fins_fiscalperiod | |
| P_CategoryFlag | wrf_catflag | |
| P_DimensionKey | dimid |
Associations (2)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [1..1] | P_CN_AlternativeGLAccountText | _AlternativeText | $projection.CompanyCode = _AlternativeText.CompanyCode and $projection.AlternativeGLAccount = _AlternativeText.GLAccount and _AlternativeText.Language = $session.system_language |
| [1..1] | I_Supplier | _Supplier | $projection.Supplier = _Supplier.Supplier |
Annotations (7)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PCNSUPLRACCTBAL | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| VDM.private | true | view | |
| VDM.viewType | #COMPOSITE | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view |
Fields (31)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | CompanyCode | CompanyCode | Receiver Company Code | |
| KEY | FiscalYear | FiscalYear | G/L Fiscal Year | |
| KEY | FiscalPeriod | FiscalPeriod | Tax period | |
| KEY | FiscalYearPeriod | |||
| KEY | GLAccount | GLAccount | General Ledger | |
| KEY | AlternativeGLAccount | AlternativeGLAccount | Group Account | |
| KEY | BusinessPartner | |||
| KEY | Customer | Customer | Sold-to Party | |
| KEY | Supplier | Supplier | Supplier | |
| KEY | AggrProfitCenter | AggrProfitCenter | ||
| KEY | AggrSegment | AggrSegment | ||
| KEY | DisplayCurrency | DisplayCurrency | Display Currency | |
| SupplierName | _Supplier | SupplierName | Supplier Name | |
| BPSupplierName | _Supplier | BPSupplierName | Supplier Name | |
| SupplierSearchTerm | ||||
| OrganizationBPName1 | _Supplier | OrganizationBPName1 | Name 1 | |
| OrganizationBPName2 | _Supplier | OrganizationBPName2 | Name 2 | |
| SupplierAccountGroup | _Supplier | SupplierAccountGroup | Account group | |
| SupplierVATRegistration | _Supplier | TaxNumber5 | ||
| SupplierCountry | ||||
| SupplierCityName | ||||
| SupplierRegion | ||||
| BusinessPartnerName | ||||
| BalCarFwdAmtInDspCrcy | CarryFwdAmtInDspCrcy | |||
| StartingBalAmtInDspCrcy | StartingBalAmtInDspCrcy | |||
| EndingBalAmtInDspCrcy | EndingBalAmtInDspCrcy | |||
| DebitAmountInDspCrcy | DebitAmtInDspCrcy | |||
| CreditAmountInDspCrcy | CreditAmtInDspCrcy | |||
| YTDDebitAmtInDspCrcy | YTDDebitAmtInDspCrcy | |||
| YTDCrdtAmtInDspCrcy | YTDCrdtAmtInDspCrcy | |||
| _AlternativeText | _AlternativeText |
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_CN_SuplrAcctBal.
-- 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: PCNSUPLRACCTBAL
-- Parameters: P_CompanyCode : bukrs, P_FiscalYear : gjahr, P_CurrencyRole : fac_crcyrole, P_ReportingFiscalPeriod : fins_fiscalperiod, P_CategoryFlag : wrf_catflag, P_DimensionKey : dimid
CREATE VIEW P_CN_SuplrAcctBal AS
SELECT
CompanyCode,
FiscalYear,
FiscalPeriod,
concat(FiscalYear,concat( '.', substring(FiscalPeriod,2,2))) AS FiscalYearPeriod,
GLAccount,
AlternativeGLAccount,
_Supplier._SupplierToBusinessPartner._BusinessPartner.BusinessPartner AS BusinessPartner,
Customer,
Supplier,
AggrProfitCenter,
AggrSegment,
DisplayCurrency,
_Supplier.SupplierName AS SupplierName,
_Supplier.BPSupplierName AS BPSupplierName,
_Supplier._SupplierToBusinessPartner._BusinessPartner.SearchTerm1 AS SupplierSearchTerm,
_Supplier.OrganizationBPName1 AS OrganizationBPName1,
_Supplier.OrganizationBPName2 AS OrganizationBPName2,
_Supplier.SupplierAccountGroup AS SupplierAccountGroup,
_Supplier.TaxNumber5 AS SupplierVATRegistration,
_Supplier._AddressRepresentation.Country AS SupplierCountry,
_Supplier._AddressRepresentation.CityName AS SupplierCityName,
_Supplier._AddressRepresentation.Region AS SupplierRegion,
_Supplier._SupplierToBusinessPartner._BusinessPartner.BusinessPartnerName AS BusinessPartnerName,
CarryFwdAmtInDspCrcy AS BalCarFwdAmtInDspCrcy,
StartingBalAmtInDspCrcy,
EndingBalAmtInDspCrcy,
DebitAmtInDspCrcy AS DebitAmountInDspCrcy,
CreditAmtInDspCrcy AS CreditAmountInDspCrcy,
YTDDebitAmtInDspCrcy,
YTDCrdtAmtInDspCrcy
FROM P_CN_BPAcctBalTF
LEFT OUTER JOIN P_CN_AlternativeGLAccountText AS _AlternativeText ON CompanyCode = _AlternativeText.CompanyCode AND AlternativeGLAccount = _AlternativeText.GLAccount AND _AlternativeText.Language = $session.system_language -- association [1..1]
LEFT OUTER JOIN I_Supplier AS _Supplier ON Supplier = _Supplier.Supplier -- 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