P_PRODALLOCPLNGBUSPARTNERS

CDS View

P_PRODALLOCPLNGBUSPARTNERS is a CDS View in S/4HANA. It contains 2 fields. 1 CDS views read from this table.

CDS Views using this table (1)

ViewTypeJoinVDMDescription
P_ProdAllocPlngBusPartValHelp view inner COMPOSITE

Fields (2)

KeyField CDS FieldsUsed in Views
BusinessPartner BusinessPartner 1
BusinessPartnerName BusinessPartnerName 1
@VDM.private: true
@VDM.viewType: #COMPOSITE
@AbapCatalog.sqlViewName: 'PPABOBJ_PLNGBPS'
@AccessControl.authorizationCheck: #NOT_REQUIRED
@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType.serviceQuality: #C
@ObjectModel.usageType.sizeCategory: #M
@ObjectModel.usageType.dataClass: #MASTER

// Since this view is used in a generic characteristic F4-help, which works for

// characteristics and accesses this view with a generic select statement getting

// view name and field names from the CharacteristicCatalogPath meta data, we cannot

// use a DCL on this view with corresponding BusinessPartner authorization objects

// for the diffrent roles (Customer, Supplier, Contact, Employee). In order to

// fulfill the Data Privacy & Protection standards for preventing blocked business

// partners from being displayed in the F4-helpm, we need to direclty access

// the blocking indicators of the different business partner roles.

// The employee has a different blocking logic (DP&P handling) and only returns

// in employee view I_Employmentshlp non-terminated employees and also only

// current and future employees which cannot be blocked.


define view P_ProdAllocPlngBusPartners
  as select from I_Customer as customer
{
  key  ltrim(customer.Customer,' ')                 as BusinessPartner,

  key  'KU'                                         as SDDocumentPartnerType,      //IF_PROD_ALLOC_CHARC_CATALOG_C=>SC_CUSTOMER-PARTNER_TYPE


       customer.CustomerName                        as BusinessPartnerName
}
where customer.IsBusinessPurposeCompleted = '' 

union

select from I_Supplier as vendor
{
  key  ltrim(vendor.Supplier,' ')                   as BusinessPartner,

  key  'LI'                                         as SDDocumentPartnerType,      //IF_PROD_ALLOC_CHARC_CATALOG_C=>SC_VENDOR-PARTNER_TYPE


       vendor.SupplierName                          as BusinessPartnerName
}
where vendor.IsBusinessPurposeCompleted = ''

union

select from I_ContactPerson as contact
{
  key  ltrim(contact.ContactPerson,' ')             as BusinessPartner,

  key  'AP'                                         as SDDocumentPartnerType, //IF_PROD_ALLOC_CHARC_CATALOG_C=>SC_CONTACT_PERSONS-PARTNER_TYPE


       case

       when contact.FirstName <> '' or contact.LastName <> ''

         then substring(rtrim(replace(concat(contact.FirstName, concat(' &@', contact.LastName)), '&@', ''),' '),1,80) 

       else ''

       end                                          as BusinessPartnerName
}
where contact.IsBusinessPurposeCompleted = ''

union

select from I_PersWrkAgrmtAllSrchHelp  as employee
{

  key  ltrim(employee.PersonWorkAgreement,' ')      as BusinessPartner,

  key  'PE'                                         as SDDocumentPartnerType, //IF_PROD_ALLOC_CHARC_CATALOG_C=>SC_PERSONNEL_NUMBER-PARTNER_TYPE


      employee.PersonFullName                       as BusinessPartnerName
}
where employee.IsBusinessPurposeCompleted = ''