P_CustomerByExternalID
Customer By External ID
P_CustomerByExternalID is a Consumption CDS View that provides data about "Customer By External ID" in SAP S/4HANA. It reads from 1 data source (I_Customer) and exposes 4 fields with key fields Customer, BusinessPartner, BPIdentificationType, BPIdentificationNumber. Part of development package ODATA_GL_DSP_DOC_FLW.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_Customer | I_Customer | from |
Annotations (10)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PDDFCUSTBYEXTID | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| ObjectModel.usageType.serviceQuality | #A | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| VDM.viewType | #CONSUMPTION | view | |
| VDM.private | true | view |
Fields (4)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | Customer | I_Customer | Customer | |
| KEY | BusinessPartner | BuPaIdentification | BusinessPartner | |
| KEY | BPIdentificationType | BuPaIdentification | BPIdentificationType | |
| KEY | BPIdentificationNumber | BuPaIdentification | BPIdentificationNumber |
@AbapCatalog.sqlViewName: 'PDDFCUSTBYEXTID'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@ClientHandling.algorithm:#SESSION_VARIABLE
@AccessControl.authorizationCheck: #NOT_REQUIRED
@ObjectModel.usageType.dataClass: #MIXED
@ObjectModel.usageType.serviceQuality: #A
@ObjectModel.usageType.sizeCategory: #XL
@VDM.viewType: #CONSUMPTION
@VDM.private: true
define view P_CustomerByExternalID
as select from I_Customer
//---> BPIdentificationNumber is a key field which causes that association is not to 1, providing only the BPIdentificationType,
//that is why we use 'left outer to one join' instead of assotiation
//BP application guarantees that there will be only 1 number for BPCU01
left outer to one join I_Customer_to_BusinessPartner as CustomerToBuPa on I_Customer.Customer = CustomerToBuPa.Customer
left outer to one join I_BusinessPartner as BuPa on CustomerToBuPa.BusinessPartnerUUID = BuPa.BusinessPartnerUUID
left outer to one join I_BuPaIdentification as BuPaIdentification on BuPa.BusinessPartner = BuPaIdentification.BusinessPartner
and BuPaIdentification.BPIdentificationType = 'BPCU01'
{
key I_Customer.Customer as Customer,
key BuPaIdentification.BusinessPartner as BusinessPartner,
key BuPaIdentification.BPIdentificationType as BPIdentificationType,
key BuPaIdentification.BPIdentificationNumber as BPIdentificationNumber
}
Learn More
- What Is a CDS View in SAP S/4HANA?
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- CDS View Annotations — A Complete Guide
- 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