P_RO_SAFTCustomer
Customer Data for RO SAFT
P_RO_SAFTCustomer is a Consumption CDS View that provides data about "Customer Data for RO SAFT" in SAP S/4HANA. It reads from 6 data sources and exposes 40 fields with key fields SourceLedger, Ledger, CompanyCode, Customer, TaxID5.
Data Sources (6)
| Source | Alias | Join Type |
|---|---|---|
| I_Customer | Customer | inner |
| P_RO_SAFTCustomerVATNumber | CustomerTaxType | from |
| P_RO_SAFTCustomerVATNumber | CustomerTaxType | union_all |
| P_RO_SAFTOneTimeCustomer | otc | inner |
| P_RO_SAFTCustAcctBal | P_RO_SAFTCustAcctBal | inner |
| P_RO_SAFTCustAcctBal | P_RO_SAFTCustAcctBal | inner |
Parameters (4)
| Name | Type | Default |
|---|---|---|
| P_FromPostingDate | dats | |
| P_ToPostingDate | dats | |
| P_FiscalYear | gjahr | |
| P_AlternativeGLAccountIsUsed | saft_ro_alt_gl_account_flag |
Annotations (12)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PROSAFTCUSTOMER | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| VDM.private | true | view | |
| AccessControl.authorizationCheck | #MANDATORY | view | |
| AccessControl.personalData.blocking | #BLOCKED_DATA_INCLUDED | view | |
| ObjectModel.usageType.serviceQuality | #D | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| ObjectModel.usageType.dataClass | #MASTER | view | |
| VDM.viewType | #CONSUMPTION | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| EndUserText.label | Customer Data for RO SAFT | view |
Fields (40)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | SourceLedger | Balance | SourceLedger | Source Ledger |
| KEY | Ledger | Balance | Ledger | Ledger |
| KEY | CompanyCode | Balance | CompanyCode | Receiver Company Code |
| KEY | Customer | |||
| KEY | TaxID5 | P_RO_SAFTCustomerVATNumber | BPTaxLongNumber | VAT Registration No. |
| KEY | RO_SAFTStandardAccount | |||
| GLAccount | Balance | GLAccount | General Ledger | |
| BusinessPartner | ||||
| CustomerName | Name of Customer | |||
| CountryISOCode | ||||
| Region | Address | Region | Venue Region | |
| PostalCode | Address | PostalCode | Postal Code | |
| CityName | Address | CityName | Name | |
| StreetName | Address | StreetName | Text | |
| HouseNumber | Address | HouseNumber | House Number | |
| Building | Address | Building | Building code | |
| StartingBalanceAmtInCoCodeCrcy | ||||
| EndingBalanceAmtInCoCodeCrcy | ||||
| P_FromPostingDate | ||||
| P_ToPostingDate | ||||
| P_FiscalYear | ||||
| SourceLedger | Source Ledger | |||
| KEY | Ledger | Balance | Ledger | Ledger |
| KEY | CompanyCode | Balance | CompanyCode | Receiver Company Code |
| KEY | Customer | |||
| KEY | TaxID5 | P_RO_SAFTOneTimeCustomer | VATRegistration | VAT Registration No. |
| KEY | RO_SAFTStandardAccount | |||
| GLAccount | Balance | GLAccount | General Ledger | |
| BusinessPartner | ||||
| CustomerName | P_RO_SAFTOneTimeCustomer | CustomerName | Name of Customer | |
| CountryISOCode | P_RO_SAFTOneTimeCustomer | CountryISOCode | ||
| Region | P_RO_SAFTOneTimeCustomer | Region | Venue Region | |
| PostalCode | P_RO_SAFTOneTimeCustomer | PostalCode | Postal Code | |
| CityName | P_RO_SAFTOneTimeCustomer | CityName | Name | |
| StreetName | P_RO_SAFTOneTimeCustomer | StreetName | Text | |
| HouseNumber | House Number | |||
| Building | Building code | |||
| StartingBalanceAmtInCoCodeCrcy | ||||
| EndingBalanceAmtInCoCodeCrcy | ||||
| CompanyCodeCurrency | Balance | CompanyCodeCurrency | Local Currency |
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_RO_SAFTCustomer.
-- 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: PROSAFTCUSTOMER
-- Parameters: P_FromPostingDate : dats, P_ToPostingDate : dats, P_FiscalYear : gjahr, P_AlternativeGLAccountIsUsed : saft_ro_alt_gl_account_flag
CREATE VIEW P_RO_SAFTCustomer AS
SELECT
Balance.SourceLedger AS SourceLedger,
Balance.Ledger AS Ledger,
Balance.CompanyCode AS CompanyCode,
max(Balance.Customer) AS Customer,
CustomerTaxType.BPTaxLongNumber AS TaxID5,
coalesce(Account.RO_SAFTStandardAccount, Balance.ActiveGLAccount) AS RO_SAFTStandardAccount,
Balance.GLAccount AS GLAccount,
max(Customer._CustomerToBusinessPartner._BusinessPartner.BusinessPartner) AS BusinessPartner,
concat_with_space(Address.OrganizationName1, concat_with_space(Address.OrganizationName2, concat_with_space(Address.OrganizationName3, Address.OrganizationName4, 1), 1), 1) AS CustomerName,
cast( Address._Country.CountryISOCode as land1 ) AS CountryISOCode,
Address.Region AS Region,
Address.PostalCode AS PostalCode,
Address.CityName AS CityName,
Address.StreetName AS StreetName,
Address.HouseNumber AS HouseNumber,
Address.Building AS Building,
sum(Balance.StartingBalanceAmtInCoCodeCrcy) AS StartingBalanceAmtInCoCodeCrcy,
sum(Balance.EndingBalanceAmtInCoCodeCrcy) AS EndingBalanceAmtInCoCodeCrcy,
Balance.CompanyCodeCurrency AS P_FromPostingDate,
P_ToPostingDate: $parameters.P_ToPostingDate AS P_ToPostingDate,
P_FiscalYear: $parameters.P_FiscalYear AS P_FiscalYear,
Balance.CompanyCodeCurrency AS CompanyCodeCurrency
FROM P_RO_SAFTCustomerVATNumber AS CustomerTaxType
INNER JOIN P_RO_SAFTCustAcctBal ON /* join condition not captured in parsed metadata */
INNER JOIN I_Customer AS Customer ON /* join condition not captured in parsed metadata */
INNER JOIN P_RO_SAFTOneTimeCustomer AS otc ON /* join condition not captured in parsed metadata */
-- UNION ALL with additional select branch(es): P_RO_SAFTCustomerVATNumber
;
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