A_BillingDocumentItemPartner

DDL: A_BILLINGDOCUMENTITEMPARTNER Type: view COMPOSITE

Item Partner

A_BillingDocumentItemPartner is a Composite CDS View that provides data about "Item Partner" in SAP S/4HANA. It reads from 1 data source (I_BillingDocItemPartner) and exposes 12 fields with key fields BillingDocument, BillingDocumentItem, PartnerFunction. It has 3 associations to related views.

Data Sources (1)

SourceAliasJoin Type
I_BillingDocItemPartner I_BillingDocItemPartner from

Associations (3)

CardinalityTargetAliasCondition
[1..1] A_BillingDocument _BillingDocument _BillingDocument.BillingDocument = $projection.BillingDocument
[1..1] A_BillingDocumentItem _BillingDocumentItem _BillingDocumentItem.BillingDocument = $projection.BillingDocument and _BillingDocumentItem.BillingDocumentItem = $projection.BillingDocumentItem
[0..1] I_BusPartAddress _BusinessPartnerAddressCP I_BillingDocItemPartner.AddressID = _BusinessPartnerAddressCP.AddressID and $projection.ContactPerson is not initial and I_BillingDocItemPartner.SDDocPartnerAddressRefType = 'I'

Annotations (15)

NameValueLevelField
ClientHandling.algorithm #SESSION_VARIABLE view
EndUserText.label Item Partner view
VDM.viewType #COMPOSITE view
VDM.lifecycle.contract.type #PUBLIC_REMOTE_API view
AbapCatalog.sqlViewName ASDBILDOCITPARTN view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #CHECK view
ObjectModel.createEnabled false view
ObjectModel.updateEnabled false view
ObjectModel.deleteEnabled false view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #XL view
Metadata.ignorePropagatedAnnotations true view

Fields (12)

KeyFieldSource TableSource FieldDescription
KEY BillingDocument BillingDocument
KEY BillingDocumentItem BillingDocumentItem
KEY PartnerFunction PartnerFunction
Customer Customer
Supplier Supplier
Personnel Personnel
ContactPerson ContactPerson
BPRefAddrForDocSpcfcAddrUUID _BPRefAddressForDocSpcfcAddr AddressUUID
BillingDocumentType _BillingDocument BillingDocumentType
SalesOrganization _BillingDocument SalesOrganization
_BillingDocument _BillingDocument
_BillingDocumentItem _BillingDocumentItem
@ClientHandling.algorithm:#SESSION_VARIABLE
@EndUserText.label: 'Item Partner'
@VDM: {
  viewType: #COMPOSITE,
  lifecycle.contract.type: #PUBLIC_REMOTE_API
}
@AbapCatalog: {
  sqlViewName: 'ASDBILDOCITPARTN',
  compiler.compareFilter: true,
  preserveKey: true
}
@AccessControl: {
  authorizationCheck: #CHECK,
  personalData.blocking: #('TRANSACTIONAL_DATA')
}
@ObjectModel: {
  createEnabled: false,
  updateEnabled: false,
  deleteEnabled: false,
  usageType: {
    dataClass: #TRANSACTIONAL,
    serviceQuality: #C,
    sizeCategory: #XL
  }
} 
@Metadata: {
  ignorePropagatedAnnotations: true
}

// I T E M PARTNER



define view A_BillingDocumentItemPartner 
  as select from I_BillingDocItemPartner //as Partner


  association [1..1] to A_BillingDocument     as _BillingDocument     on  _BillingDocument.BillingDocument = $projection.BillingDocument
  association [1..1] to A_BillingDocumentItem as _BillingDocumentItem on  _BillingDocumentItem.BillingDocument     = $projection.BillingDocument
                                                                      and _BillingDocumentItem.BillingDocumentItem = $projection.BillingDocumentItem
  association [0..1] to I_BusPartAddress         as _BusinessPartnerAddressCP      on I_BillingDocItemPartner.AddressID                  = _BusinessPartnerAddressCP.AddressID
                                                                                    and $projection.ContactPerson is not initial
                                                                                    and I_BillingDocItemPartner.SDDocPartnerAddressRefType =  'I'


{
  
  //key cast(SDDocument as vbeln_vf preserving type) as BillingDocument,

  key BillingDocument,
  
  //key cast(SDDocumentItem as posnr_vf preserving type) as BillingDocumentItem,

  key BillingDocumentItem,
  
      @ObjectModel.sapObjectNodeTypeReference: 'PartnerFunction'        
  key PartnerFunction,

      Customer,

      Supplier,

      Personnel,

      ContactPerson,
      
      @Feature: 'SW:Q2C_MULTIPLE_BP_ADDRESSES, SW:Q2C_MULTIPLE_BP_ADDRESSES2'
      case ContactPerson
        when '0000000000' then
         _BusinessPartnerAddress.AddressUUID
       else
         _BusinessPartnerAddressCP.AddressUUID
                                                    end as BusinessPartnerAddressUUID,
      
      @Feature: 'SW:Q2C_MULTIPLE_BP_ADDRESSES, SW:Q2C_MULTIPLE_BP_ADDRESSES2'
      @ObjectModel.readOnly: true  
      _BPRefAddressForDocSpcfcAddr.AddressUUID  as BPRefAddrForDocSpcfcAddrUUID, 

      // For Access control

      @Consumption.hidden: true
      _BillingDocument.BillingDocumentType, // as BillingDocumentType,

      @Consumption.hidden: true
      _BillingDocument.SalesOrganization, //

     

      //Expose associations

      _BillingDocument,
      _BillingDocumentItem
}
where I_BillingDocItemPartner._BillingDocument.BillingDocumentIsTemporary = ' '
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"A_BILLINGDOCUMENT",
"I_BILLINGDOCITEMPARTNER",
"I_BILLINGDOCUMENT",
"I_BUSPARTADDRESS"
],
"ASSOCIATED":
[
"A_BILLINGDOCUMENT",
"A_BILLINGDOCUMENTITEM",
"I_BUSPARTADDRESS"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/