P_ARCustomerUnion
AR Customer Union
P_ARCustomerUnion is a Consumption CDS View that provides data about "AR Customer Union" in SAP S/4HANA. It reads from 5 data sources (I_Customer, I_Customer, I_CustomerCompany, P_ARCustomerSalesArea, P_ARCustomerSalesArea) and exposes 121 fields with key fields Customer, CompanyCode, SalesOrganization, DistributionChannel, Division. It has 2 associations to related views.
Data Sources (5)
| Source | Alias | Join Type |
|---|---|---|
| I_Customer | _C | from |
| I_Customer | _C | union_all |
| I_CustomerCompany | _CC | left_outer |
| P_ARCustomerSalesArea | _CSA | left_outer |
| P_ARCustomerSalesArea | _CSA | left_outer |
Associations (2)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_CustomerCompany | _CustomerCompany | $projection.Customer = _CustomerCompany.Customer and $projection.CompanyCode = _CustomerCompany.CompanyCode |
| [0..1] | I_CustomerSalesArea | _CustomerSalesArea | $projection.Customer = _CustomerSalesArea.Customer and $projection.SalesOrganization = _CustomerSalesArea.SalesOrganization and $projection.DistributionChannel = _CustomerSalesArea.DistributionChannel and $projection.Division = _CustomerSalesArea.Division |
Annotations (7)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PARCUSTOMERUN | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| EndUserText.label | AR Customer Union | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| VDM.viewType | #CONSUMPTION | view | |
| VDM.private | true | view |
Fields (121)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | Customer | I_Customer | Customer | Sold-to Party |
| KEY | CompanyCode | I_CustomerCompany | CompanyCode | Receiver Company Code |
| KEY | SalesOrganization | P_ARCustomerSalesArea | SalesOrganization | Sales Organization |
| KEY | DistributionChannel | P_ARCustomerSalesArea | DistributionChannel | RefDistCh-Cust/Mat. |
| KEY | Division | P_ARCustomerSalesArea | Division | Internal Division ID |
| KEY | CustomerIsWithCompanyCode | |||
| CustomerAccountGroup | I_Customer | CustomerAccountGroup | Account group | |
| _CustomerAccountGroupText | I_Customer | _CustomerAccountGroupText | ||
| Supplier | I_Customer | Supplier | Supplier | |
| PostingIsBlocked | I_Customer | PostingIsBlocked | Posting Block | |
| AuthorizationGroup | I_Customer | AuthorizationGroup | AuthorizGroup | |
| CreatedByUser | I_Customer | CreatedByUser | User Name | |
| VATRegistration | I_Customer | VATRegistration | VAT Registration No. | |
| TaxNumber1 | I_Customer | TaxNumber1 | VAT Reg. No. | |
| TaxNumber2 | I_Customer | TaxNumber2 | Tax Number 2 | |
| TaxNumber3 | I_Customer | TaxNumber3 | ||
| TaxNumber4 | I_Customer | TaxNumber4 | ||
| TaxNumber5 | I_Customer | TaxNumber5 | ||
| VATLiability | I_Customer | VATLiability | Liable for VAT | |
| ResponsibleType | I_Customer | ResponsibleType | Tax Type | |
| TaxNumberType | I_Customer | TaxNumberType | Tax number type | |
| CustomerName | I_Customer | CustomerName | Name of Customer | |
| CustomerFullName | I_Customer | CustomerFullName | Customer Name | |
| AddressID | I_Customer | AddressID | Ship-to address | |
| SalesOffice | _CustomerSalesArea | SalesOffice | Sales Office | |
| SalesGroup | _CustomerSalesArea | SalesGroup | Sales Group | |
| CustomerPaymentTerms | _CustomerSalesArea | CustomerPaymentTerms | Pyt Terms | |
| AccountingClerk | _CustomerCompany | AccountingClerk | Clerk Abbrev. | |
| PaymentTerms | _CustomerCompany | PaymentTerms | Pyt Terms | |
| PhysicalInventoryBlockInd | _CustomerCompany | PhysicalInventoryBlockInd | Phys. Inv. Blk | |
| CreditMemoPaymentTerms | _CustomerCompany | CreditMemoPaymentTerms | Cr Memo Terms | |
| PaymentMethodsList | _CustomerCompany | PaymentMethodsList | Payment Methods | |
| HouseBank | _CustomerCompany | HouseBank | House Bank | |
| PaymentBlockingReason | _CustomerCompany | PaymentBlockingReason | Pmnt block | |
| DunningNoticeGroup | _CustomerCompany | DunningNoticeGroup | Grouping Key | |
| AccountByCustomer | _CustomerCompany | AccountByCustomer | Acct at cust. | |
| UserAtCustomer | _CustomerCompany | UserAtCustomer | Customer user | |
| AccountingClerkPhoneNumber | _CustomerCompany | AccountingClerkPhoneNumber | Act.clk tel.no. | |
| AccountingClerkInternetAddress | _CustomerCompany | AccountingClerkInternetAddress | Clrk's internet | |
| ReconciliationAccount | _CustomerCompany | ReconciliationAccount | Recon. account | |
| InterestCalculationCode | _CustomerCompany | InterestCalculationCode | Interest Indic. | |
| IntrstCalcFrequencyInMonths | _CustomerCompany | IntrstCalcFrequencyInMonths | Int.Calc.Freq. | |
| InterestCalculationDate | _CustomerCompany | InterestCalculationDate | Last Key Date | |
| LastInterestCalcRunDate | _CustomerCompany | LastInterestCalcRunDate | Last Int. Calc. | |
| CustPreviousMasterRecordNumber | _CustomerCompany | CustPreviousMasterRecordNumber | Prev.Acct No. | |
| CashPlanningGroup | _CustomerCompany | CashPlanningGroup | Planning Group | |
| _CustomerToBusinessPartner | I_Customer | _CustomerToBusinessPartner | ||
| _StandardAddress | I_Customer | _StandardAddress | ||
| _CustomerCompany | _CustomerCompany | |||
| _CustomerSalesArea | _CustomerSalesArea | |||
| DataControllerSet | I_Customer | DataControllerSet | Data Ctrlr. Set | |
| DataController1 | I_Customer | DataController1 | Data Controller | |
| DataController2 | I_Customer | DataController2 | Data Controller | |
| DataController3 | I_Customer | DataController3 | Data Controller | |
| DataController4 | I_Customer | DataController4 | Data Controller | |
| DataController5 | I_Customer | DataController5 | Data Controller | |
| DataController6 | I_Customer | DataController6 | Data Controller | |
| DataController7 | I_Customer | DataController7 | Data Controller | |
| DataController8 | I_Customer | DataController8 | Data Controller | |
| DataController9 | I_Customer | DataController9 | Data Controller | |
| Customer | Sold-to Party | |||
| KEY | CompanyCode | I_CustomerCompany | CompanyCode | Receiver Company Code |
| KEY | SalesOrganization | P_ARCustomerSalesArea | SalesOrganization | Sales Organization |
| KEY | DistributionChannel | P_ARCustomerSalesArea | DistributionChannel | RefDistCh-Cust/Mat. |
| KEY | Division | P_ARCustomerSalesArea | Division | Internal Division ID |
| KEY | CustomerIsWithCompanyCode | |||
| CustomerAccountGroup | I_Customer | CustomerAccountGroup | Account group | |
| _CustomerAccountGroupText | I_Customer | _CustomerAccountGroupText | ||
| Supplier | I_Customer | Supplier | Supplier | |
| PostingIsBlocked | I_Customer | PostingIsBlocked | Posting Block | |
| AuthorizationGroup | I_Customer | AuthorizationGroup | AuthorizGroup | |
| CreatedByUser | I_Customer | CreatedByUser | User Name | |
| VATRegistration | I_Customer | VATRegistration | VAT Registration No. | |
| TaxNumber1 | I_Customer | TaxNumber1 | VAT Reg. No. | |
| TaxNumber2 | I_Customer | TaxNumber2 | Tax Number 2 | |
| TaxNumber3 | I_Customer | TaxNumber3 | ||
| TaxNumber4 | I_Customer | TaxNumber4 | ||
| TaxNumber5 | I_Customer | TaxNumber5 | ||
| VATLiability | I_Customer | VATLiability | Liable for VAT | |
| ResponsibleType | I_Customer | ResponsibleType | Tax Type | |
| TaxNumberType | I_Customer | TaxNumberType | Tax number type | |
| CustomerName | I_Customer | CustomerName | Name of Customer | |
| CustomerFullName | I_Customer | CustomerFullName | Customer Name | |
| AddressID | I_Customer | AddressID | Ship-to address | |
| SalesOffice | _CustomerSalesArea | SalesOffice | Sales Office | |
| SalesGroup | _CustomerSalesArea | SalesGroup | Sales Group | |
| CustomerPaymentTerms | _CustomerSalesArea | CustomerPaymentTerms | Pyt Terms | |
| AccountingClerk | _CustomerCompany | AccountingClerk | Clerk Abbrev. | |
| PaymentTerms | _CustomerCompany | PaymentTerms | Pyt Terms | |
| PhysicalInventoryBlockInd | _CustomerCompany | PhysicalInventoryBlockInd | Phys. Inv. Blk | |
| CreditMemoPaymentTerms | _CustomerCompany | CreditMemoPaymentTerms | Cr Memo Terms | |
| PaymentMethodsList | _CustomerCompany | PaymentMethodsList | Payment Methods | |
| HouseBank | _CustomerCompany | HouseBank | House Bank | |
| PaymentBlockingReason | _CustomerCompany | PaymentBlockingReason | Pmnt block | |
| DunningNoticeGroup | _CustomerCompany | DunningNoticeGroup | Grouping Key | |
| AccountByCustomer | _CustomerCompany | AccountByCustomer | Acct at cust. | |
| UserAtCustomer | _CustomerCompany | UserAtCustomer | Customer user | |
| AccountingClerkPhoneNumber | _CustomerCompany | AccountingClerkPhoneNumber | Act.clk tel.no. | |
| AccountingClerkInternetAddress | _CustomerCompany | AccountingClerkInternetAddress | Clrk's internet | |
| ReconciliationAccount | _CustomerCompany | ReconciliationAccount | Recon. account | |
| InterestCalculationCode | _CustomerCompany | InterestCalculationCode | Interest Indic. | |
| IntrstCalcFrequencyInMonths | _CustomerCompany | IntrstCalcFrequencyInMonths | Int.Calc.Freq. | |
| InterestCalculationDate | _CustomerCompany | InterestCalculationDate | Last Key Date | |
| LastInterestCalcRunDate | _CustomerCompany | LastInterestCalcRunDate | Last Int. Calc. | |
| CustPreviousMasterRecordNumber | _CustomerCompany | CustPreviousMasterRecordNumber | Prev.Acct No. | |
| CashPlanningGroup | _CustomerCompany | CashPlanningGroup | Planning Group | |
| _CustomerToBusinessPartner | I_Customer | _CustomerToBusinessPartner | ||
| _StandardAddress | I_Customer | _StandardAddress | ||
| _CustomerCompany | _CustomerCompany | |||
| _CustomerSalesArea | _CustomerSalesArea | |||
| DataControllerSet | I_Customer | DataControllerSet | Data Ctrlr. Set | |
| DataController1 | I_Customer | DataController1 | Data Controller | |
| DataController2 | I_Customer | DataController2 | Data Controller | |
| DataController3 | I_Customer | DataController3 | Data Controller | |
| DataController4 | I_Customer | DataController4 | Data Controller | |
| DataController5 | I_Customer | DataController5 | Data Controller | |
| DataController6 | I_Customer | DataController6 | Data Controller | |
| DataController7 | I_Customer | DataController7 | Data Controller | |
| DataController8 | I_Customer | DataController8 | Data Controller | |
| DataController9 | I_Customer | DataController9 | Data Controller | |
| DataController10 | I_Customer | DataController10 | Data Controller |
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_ARCustomerUnion.
-- 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: PARCUSTOMERUN
CREATE VIEW P_ARCustomerUnion AS
SELECT
_C.Customer AS Customer,
_CC.CompanyCode AS CompanyCode,
_CSA.SalesOrganization AS SalesOrganization,
_CSA.DistributionChannel AS DistributionChannel,
_CSA.Division AS Division,
'X' AS CustomerIsWithCompanyCode,
_C.CustomerAccountGroup AS CustomerAccountGroup,
_C._CustomerAccountGroupText AS _CustomerAccountGroupText,
_C.Supplier AS Supplier,
_C.PostingIsBlocked AS PostingIsBlocked,
_C.AuthorizationGroup AS AuthorizationGroup,
_C.CreatedByUser AS CreatedByUser,
_C.VATRegistration AS VATRegistration,
_C.TaxNumber1 AS TaxNumber1,
_C.TaxNumber2 AS TaxNumber2,
_C.TaxNumber3 AS TaxNumber3,
_C.TaxNumber4 AS TaxNumber4,
_C.TaxNumber5 AS TaxNumber5,
_C.VATLiability AS VATLiability,
_C.ResponsibleType AS ResponsibleType,
_C.TaxNumberType AS TaxNumberType,
_C.CustomerName AS CustomerName,
_C.CustomerFullName AS CustomerFullName,
_C.AddressID AS AddressID,
_CustomerSalesArea.SalesOffice AS SalesOffice,
_CustomerSalesArea.SalesGroup AS SalesGroup,
_CustomerSalesArea.CustomerPaymentTerms AS CustomerPaymentTerms,
_CustomerCompany.AccountingClerk AS AccountingClerk,
_CustomerCompany.PaymentTerms AS PaymentTerms,
_CustomerCompany.PhysicalInventoryBlockInd AS PhysicalInventoryBlockInd,
_CustomerCompany.CreditMemoPaymentTerms AS CreditMemoPaymentTerms,
_CustomerCompany.PaymentMethodsList AS PaymentMethodsList,
_CustomerCompany.HouseBank AS HouseBank,
_CustomerCompany.PaymentBlockingReason AS PaymentBlockingReason,
_CustomerCompany.DunningNoticeGroup AS DunningNoticeGroup,
_CustomerCompany.AccountByCustomer AS AccountByCustomer,
_CustomerCompany.UserAtCustomer AS UserAtCustomer,
_CustomerCompany.AccountingClerkPhoneNumber AS AccountingClerkPhoneNumber,
_CustomerCompany.AccountingClerkInternetAddress AS AccountingClerkInternetAddress,
_CustomerCompany.ReconciliationAccount AS ReconciliationAccount,
_CustomerCompany.InterestCalculationCode AS InterestCalculationCode,
_CustomerCompany.IntrstCalcFrequencyInMonths AS IntrstCalcFrequencyInMonths,
_CustomerCompany.InterestCalculationDate AS InterestCalculationDate,
_CustomerCompany.LastInterestCalcRunDate AS LastInterestCalcRunDate,
_CustomerCompany.CustPreviousMasterRecordNumber AS CustPreviousMasterRecordNumber,
_CustomerCompany.CashPlanningGroup AS CashPlanningGroup,
_C._CustomerToBusinessPartner AS _CustomerToBusinessPartner,
_C._StandardAddress AS _StandardAddress,
_C.DataControllerSet AS DataControllerSet,
_C.DataController1 AS DataController1,
_C.DataController2 AS DataController2,
_C.DataController3 AS DataController3,
_C.DataController4 AS DataController4,
_C.DataController5 AS DataController5,
_C.DataController6 AS DataController6,
_C.DataController7 AS DataController7,
_C.DataController8 AS DataController8,
_C.DataController9 AS DataController9,
_C.DataController10 AS DataController10
FROM I_Customer AS _C
LEFT OUTER JOIN I_CustomerCompany AS _CC ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN P_ARCustomerSalesArea AS _CSA ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_CustomerCompany AS _CustomerCompany ON Customer = _CustomerCompany.Customer AND CompanyCode = _CustomerCompany.CompanyCode -- association [0..1]
LEFT OUTER JOIN I_CustomerSalesArea AS _CustomerSalesArea ON Customer = _CustomerSalesArea.Customer AND SalesOrganization = _CustomerSalesArea.SalesOrganization AND DistributionChannel = _CustomerSalesArea.DistributionChannel AND Division = _CustomerSalesArea.Division -- association [0..1]
-- UNION ALL with additional select branch(es): I_Customer
;
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