I_SalesDocItemCompletePartner
Sales Doc Item and Inherited Partners
I_SalesDocItemCompletePartner is a Composite CDS View that provides data about "Sales Doc Item and Inherited Partners" in SAP S/4HANA. It reads from 1 data source (P_SalesDocItemCompletePartner) and exposes 31 fields with key fields SalesDocument, SalesDocumentItem, PartnerFunction. It has 10 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| P_SalesDocItemCompletePartner | ItemPartner | from |
Associations (10)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [1] | I_WorkAssignment | _WorkAssignment | $projection.Personnel = _WorkAssignment.WorkAssignment |
| [0..1] | I_OrganizationAddress | _OrganizationAddress | $projection.AddressID = _OrganizationAddress.AddressID and $projection.AddressPersonID = _OrganizationAddress.AddressPersonID and $projection.AddressObjectType = '1' and _OrganizationAddress.AddressRepresentationCode is initial |
| [0..1] | I_PersonAddress | _PersonAddress | $projection.AddressID = _PersonAddress.AddressID and $projection.AddressPersonID = _PersonAddress.AddressPersonID and $projection.AddressObjectType = '2' and _PersonAddress.AddressRepresentationCode is initial |
| [0..1] | I_PersonWorkplaceAddress | _PersonWorkplaceAddress | $projection.AddressID = _PersonWorkplaceAddress.AddressID and $projection.AddressPersonID = _PersonWorkplaceAddress.AddressPersonID and $projection.AddressObjectType = '3' and _PersonWorkplaceAddress.AddressRepresentationCode is initial |
| [0..1] | I_AddrOrgNamePostalAddress | _OrgNamePostalAddress | $projection.AddressID = _OrgNamePostalAddress.AddressID and _OrgNamePostalAddress.AddressRepresentationCode is initial |
| [0..1] | I_AddressPersonName | _PersonName | $projection.AddressPersonID = _PersonName.AddressPersonID and _PersonName.AddressRepresentationCode is initial |
| [0..1] | I_AddrCurDfltLandlinePhoneNmbr | _CurrentDfltLandlinePhoneNmbr | $projection.AddressID = _CurrentDfltLandlinePhoneNmbr.AddressID and $projection.AddressPersonID = _CurrentDfltLandlinePhoneNmbr.AddressPersonID |
| [0..1] | I_AddrCurDefaultEmailAddress | _CurrentDfltEmailAddress | $projection.AddressID = _CurrentDfltEmailAddress.AddressID and $projection.AddressPersonID = _CurrentDfltEmailAddress.AddressPersonID |
| [0..1] | I_AddrCurDfltMobilePhoneNumber | _CurrentDfltMobilePhoneNumber | $projection.AddressID = _CurrentDfltMobilePhoneNumber.AddressID and $projection.AddressPersonID = _CurrentDfltMobilePhoneNumber.AddressPersonID |
| [0..1] | I_AddrCurDefaultFaxNumber | _CurrentDfltFaxNumber | $projection.AddressID = _CurrentDfltFaxNumber.AddressID and $projection.AddressPersonID = _CurrentDfltFaxNumber.AddressPersonID |
Annotations (12)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | ISLSDOCITMCMPLPT | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| VDM.viewType | #COMPOSITE | view | |
| VDM.lifecycle.contract.type | #PUBLIC_LOCAL_API | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| ObjectModel.representativeKey | PartnerFunction | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| ObjectModel.usageType.sizeCategory | #XL | view | |
| Metadata.ignorePropagatedAnnotations | true | view | |
| EndUserText.label | Sales Doc Item and Inherited Partners | view |
Fields (31)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | SalesDocument | P_SalesDocItemCompletePartner | SalesDocument | SD Document |
| KEY | SalesDocumentItem | P_SalesDocItemCompletePartner | SalesDocumentItem | Sales Document Item |
| KEY | PartnerFunction | P_SalesDocItemCompletePartner | PartnerFunction | Partner Functn |
| Customer | P_SalesDocItemCompletePartner | Customer | Sold-to Party | |
| Supplier | P_SalesDocItemCompletePartner | Supplier | Supplier | |
| ContactPerson | P_SalesDocItemCompletePartner | ContactPerson | Contact Person Key | |
| Personnel | P_SalesDocItemCompletePartner | Personnel | Personnel No. | |
| VATRegistration | P_SalesDocItemCompletePartner | VATRegistration | VAT Registration No. | |
| UnloadingPointName | P_SalesDocItemCompletePartner | UnloadingPointName | Unloading Point Name | |
| ContactPersonaskunnrelseendasPartner | ||||
| ReferenceBusinessPartner | P_SalesDocItemCompletePartner | ReferenceBusinessPartner | Busn. Partner | |
| AddressID | P_SalesDocItemCompletePartner | AddressID | Ship-to address | |
| AddressPersonID | P_SalesDocItemCompletePartner | AddressPersonID | Person Number | |
| AddressObjectType | P_SalesDocItemCompletePartner | AddressObjectType | Address Type | |
| SDDocPartnerAddressRefType | P_SalesDocItemCompletePartner | SDDocPartnerAddressRefType | Adress ind. | |
| BPAddrDeterminationTransaction | P_SalesDocItemCompletePartner | BPAddrDeterminationTransaction | Address Detn | |
| BPRefAddressIDForDocSpcfcAddr | P_SalesDocItemCompletePartner | BPRefAddressIDForDocSpcfcAddr | BP Ref. Address Num. | |
| PartnerIsSpecificForSDDocItem | P_SalesDocItemCompletePartner | PartnerIsSpecificForSDDocItem | ||
| Country | _OrgNamePostalAddress | Country | Venue: Ctry/Reg | |
| _Address | P_SalesDocItemCompletePartner | _Address | ||
| _DfltAddrRprstn | P_SalesDocItemCompletePartner | _DfltAddrRprstn | ||
| _BusinessPartnerAddress | P_SalesDocItemCompletePartner | _BusinessPartnerAddress | ||
| _BPRefAddressForDocSpcfcAddr | P_SalesDocItemCompletePartner | _BPRefAddressForDocSpcfcAddr | ||
| _SalesDocument | P_SalesDocItemCompletePartner | _SalesDocument | ||
| _SalesDocumentItem | P_SalesDocItemCompletePartner | _SalesDocumentItem | ||
| _PartnerFunction | P_SalesDocItemCompletePartner | _PartnerFunction | ||
| _ContactPerson | _ContactPerson | |||
| _PersonAddress | _PersonAddress | |||
| _PersonName | _PersonName | |||
| _OrganizationAddress | _OrganizationAddress | |||
| _OrgNamePostalAddress | _OrgNamePostalAddress |
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 I_SalesDocItemCompletePartner.
-- 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 I_SalesDocItemCompletePartner AS
SELECT
ItemPartner.SalesDocument AS SalesDocument,
ItemPartner.SalesDocumentItem AS SalesDocumentItem,
ItemPartner.PartnerFunction AS PartnerFunction,
ItemPartner.Customer AS Customer,
ItemPartner.Supplier AS Supplier,
ItemPartner.ContactPerson AS ContactPerson,
ItemPartner.Personnel AS Personnel,
ItemPartner.VATRegistration AS VATRegistration,
ItemPartner.UnloadingPointName AS UnloadingPointName,
case when ItemPartner.Customer != '' then ItemPartner.Customer when ItemPartner.Supplier != '' then ItemPartner.Supplier when ItemPartner.Personnel != '00000000' then cast(ItemPartner.Personnel as kunnr) when ItemPartner.ContactPerson != '0000000000' then cast(ItemPartner.ContactPerson as kunnr) else '' end as Partner AS ContactPersonaskunnrelseendasPartner,
ItemPartner.ReferenceBusinessPartner AS ReferenceBusinessPartner,
ItemPartner.AddressID AS AddressID,
ItemPartner.AddressPersonID AS AddressPersonID,
ItemPartner.AddressObjectType AS AddressObjectType,
ItemPartner.SDDocPartnerAddressRefType AS SDDocPartnerAddressRefType,
ItemPartner.BPAddrDeterminationTransaction AS BPAddrDeterminationTransaction,
ItemPartner.BPRefAddressIDForDocSpcfcAddr AS BPRefAddressIDForDocSpcfcAddr,
ItemPartner.PartnerIsSpecificForSDDocItem AS PartnerIsSpecificForSDDocItem,
_OrgNamePostalAddress.Country AS Country,
ItemPartner._Address AS _Address,
ItemPartner._DfltAddrRprstn AS _DfltAddrRprstn,
ItemPartner._BusinessPartnerAddress AS _BusinessPartnerAddress,
ItemPartner._BPRefAddressForDocSpcfcAddr AS _BPRefAddressForDocSpcfcAddr,
ItemPartner._SalesDocument AS _SalesDocument,
ItemPartner._SalesDocumentItem AS _SalesDocumentItem,
ItemPartner._PartnerFunction AS _PartnerFunction
FROM P_SalesDocItemCompletePartner AS ItemPartner
LEFT OUTER JOIN I_WorkAssignment AS _WorkAssignment ON Personnel = _WorkAssignment.WorkAssignment -- association [1]
LEFT OUTER JOIN I_OrganizationAddress AS _OrganizationAddress ON AddressID = _OrganizationAddress.AddressID AND AddressPersonID = _OrganizationAddress.AddressPersonID AND AddressObjectType = '1' AND _OrganizationAddress.AddressRepresentationCode is initial -- association [0..1]
LEFT OUTER JOIN I_PersonAddress AS _PersonAddress ON AddressID = _PersonAddress.AddressID AND AddressPersonID = _PersonAddress.AddressPersonID AND AddressObjectType = '2' AND _PersonAddress.AddressRepresentationCode is initial -- association [0..1]
LEFT OUTER JOIN I_PersonWorkplaceAddress AS _PersonWorkplaceAddress ON AddressID = _PersonWorkplaceAddress.AddressID AND AddressPersonID = _PersonWorkplaceAddress.AddressPersonID AND AddressObjectType = '3' AND _PersonWorkplaceAddress.AddressRepresentationCode is initial -- association [0..1]
LEFT OUTER JOIN I_AddrOrgNamePostalAddress AS _OrgNamePostalAddress ON AddressID = _OrgNamePostalAddress.AddressID AND _OrgNamePostalAddress.AddressRepresentationCode is initial -- association [0..1]
LEFT OUTER JOIN I_AddressPersonName AS _PersonName ON AddressPersonID = _PersonName.AddressPersonID AND _PersonName.AddressRepresentationCode is initial -- association [0..1]
LEFT OUTER JOIN I_AddrCurDfltLandlinePhoneNmbr AS _CurrentDfltLandlinePhoneNmbr ON AddressID = _CurrentDfltLandlinePhoneNmbr.AddressID AND AddressPersonID = _CurrentDfltLandlinePhoneNmbr.AddressPersonID -- association [0..1]
LEFT OUTER JOIN I_AddrCurDefaultEmailAddress AS _CurrentDfltEmailAddress ON AddressID = _CurrentDfltEmailAddress.AddressID AND AddressPersonID = _CurrentDfltEmailAddress.AddressPersonID -- association [0..1]
LEFT OUTER JOIN I_AddrCurDfltMobilePhoneNumber AS _CurrentDfltMobilePhoneNumber ON AddressID = _CurrentDfltMobilePhoneNumber.AddressID AND AddressPersonID = _CurrentDfltMobilePhoneNumber.AddressPersonID -- association [0..1]
LEFT OUTER JOIN I_AddrCurDefaultFaxNumber AS _CurrentDfltFaxNumber ON AddressID = _CurrentDfltFaxNumber.AddressID AND AddressPersonID = _CurrentDfltFaxNumber.AddressPersonID -- association [0..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