P_SDDocItemPartnerComplete

DDL: P_SDDOCITEMPARTNERCOMPLETE SQL: PSDOCITPARTCMPLT Type: view CONSUMPTION Package: ODATA_SD_RETURN_V2

SD Document Item Complete Partner

P_SDDocItemPartnerComplete is a Consumption CDS View that provides data about "SD Document Item Complete Partner" in SAP S/4HANA. It reads from 5 data sources (I_SDDocumentCompletePartners, I_SDDocumentItemPartner, I_SDDocumentItemPartner, I_SalesDocumentItem, I_SalesDocumentItem) and exposes 25 fields. It has 1 association to related views. Part of development package ODATA_SD_RETURN_V2.

Data Sources (5)

SourceAliasJoin Type
I_SDDocumentCompletePartners CompletePartner from
I_SDDocumentItemPartner ItemPartner left_outer
I_SDDocumentItemPartner ItemPartner union
I_SalesDocumentItem SDI left_outer
I_SalesDocumentItem SDI left_outer

Associations (1)

CardinalityTargetAliasCondition
[0..1] I_Customer _Customer $projection.Customer = _Customer.Customer

Annotations (7)

NameValueLevelField
ClientHandling.algorithm #SESSION_VARIABLE view
AbapCatalog.sqlViewName PSDOCITPARTCMPLT view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
VDM.private true view
VDM.viewType #CONSUMPTION view
AccessControl.authorizationCheck #NOT_REQUIRED view

Fields (25)

KeyFieldSource TableSource FieldDescription
SDDocument I_SDDocumentCompletePartners SDDocument SD Document
SDDocumentItem I_SDDocumentCompletePartners SDDocumentItem WBS Element
PartnerFunction I_SDDocumentCompletePartners PartnerFunction Partner Functn
CustomerendasCustomer
Personnel I_SDDocumentCompletePartners Personnel Personnel No.
AddressID I_SDDocumentCompletePartners AddressID Ship-to address
AddressPersonID I_SDDocumentCompletePartners AddressPersonID Person Number
ContactPerson I_SDDocumentCompletePartners ContactPerson Contact Person Key
_PartnerFunction I_SDDocumentCompletePartners _PartnerFunction
_Customer _Customer
_Address I_SDDocumentCompletePartners _Address
_DfltAddrRprstn I_SDDocumentCompletePartners _DfltAddrRprstn
SDDocument SD Document
SDDocumentItem I_SDDocumentItemPartner SDDocumentItem WBS Element
PartnerFunction I_SDDocumentItemPartner PartnerFunction Partner Functn
CustomerendasCustomer
Personnel I_SDDocumentItemPartner Personnel Personnel No.
AddressID I_SDDocumentItemPartner AddressID Ship-to address
AddressPersonID I_SDDocumentItemPartner AddressPersonID Person Number
ContactPerson I_SDDocumentItemPartner ContactPerson Contact Person Key
_PartnerFunction I_SDDocumentItemPartner _PartnerFunction
_Customer _Customer
_Address I_SDDocumentItemPartner _Address
_DfltAddrRprstn I_SDDocumentItemPartner _DfltAddrRprstn
SalesDocumentItem I_SalesDocumentItem SalesDocumentItem Sales Document Item

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_SDDocItemPartnerComplete.
-- 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: PSDOCITPARTCMPLT

CREATE VIEW P_SDDocItemPartnerComplete AS
SELECT
  CompletePartner.SDDocument AS SDDocument,
  CompletePartner.SDDocumentItem AS SDDocumentItem,
  CompletePartner.PartnerFunction AS PartnerFunction,
  case when CompletePartner.Supplier <> '' then CompletePartner.Supplier else CompletePartner.Customer end as Customer AS CustomerendasCustomer,
  CompletePartner.Personnel AS Personnel,
  CompletePartner.AddressID AS AddressID,
  CompletePartner.AddressPersonID AS AddressPersonID,
  CompletePartner.ContactPerson AS ContactPerson,
  CompletePartner._PartnerFunction AS _PartnerFunction,
  CompletePartner._Address AS _Address,
  CompletePartner._DfltAddrRprstn AS _DfltAddrRprstn,
  SDI.SalesDocumentItem AS SalesDocumentItem
FROM I_SDDocumentCompletePartners AS CompletePartner
LEFT OUTER JOIN I_SDDocumentItemPartner AS ItemPartner ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_SalesDocumentItem AS SDI ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_Customer AS _Customer ON Customer = _Customer.Customer  -- association [0..1]
-- UNION with additional select branch(es): I_SDDocumentItemPartner
;