I_BusPartContactPersonGovTP

DDL: I_BUSPARTCONTACTPERSONGOVTP Type: view_entity TRANSACTIONAL

BP Relationship Contact Person Data - TP

I_BusPartContactPersonGovTP is a Transactional CDS View that provides data about "BP Relationship Contact Person Data - TP" in SAP S/4HANA. It reads from 2 data sources (I_BusPartContactPersonGov, I_BusPartRelationshipGov) and exposes 28 fields with key fields BPRelshpUUID, MasterDataChangeProcess, MDChgProcessSrceSystem, MDChgProcessSrceObject, BPRelshpCatIsInFwdDirection. It has 4 associations to related views.

Data Sources (2)

SourceAliasJoin Type
I_BusPartContactPersonGov _ContactPersonData inner
I_BusPartRelationshipGov _Current from

Associations (4)

CardinalityTargetAliasCondition
[1..*] I_ContactPersonDepartmentT _ContactPersonDepartmentText $projection.ContactPersonDepartment = _ContactPersonDepartmentText.ContactPersonDepartment
[0..*] I_ContactPersonFunctionT _ContactPersonFunctionText $projection.ContactPersonFunction = _ContactPersonFunctionText.ContactPersonFunction
[1..*] I_BPContactPersonAuthorityText _BPContactPersonAuthorityText $projection.ContactPersonAuthorityType = _BPContactPersonAuthorityText.ContactPersonAuthorityType
[1..*] I_BPCntctPersnVIPIndicatorText _BPCntctPersnVIPIndicatorText $projection.ContactPersonVIPType = _BPCntctPersnVIPIndicatorText.ContactPersonVIPType

Annotations (6)

NameValueLevelField
AccessControl.authorizationCheck #CHECK view
EndUserText.label BP Relationship Contact Person Data - TP view
ObjectModel.usageType.serviceQuality #X view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.sizeCategory #XL view
VDM.viewType #TRANSACTIONAL view

Fields (28)

KeyFieldSource TableSource FieldDescription
KEY BPRelshpUUID
KEY MasterDataChangeProcess I_BusPartRelationshipGov MasterDataChangeProcess
KEY MDChgProcessSrceSystem I_BusPartRelationshipGov MDChgProcessSrceSystem
KEY MDChgProcessSrceObject I_BusPartRelationshipGov MDChgProcessSrceObject
KEY BPRelshpCatIsInFwdDirection I_BusPartRelationshipGov BPRelshpCatIsInFwdDirection
MDChgProcessStep I_BusPartRelationshipGov MDChgProcessStep
ContactPersonFunction I_BusPartContactPersonGov ContactPersonFunction
ContactPersonFunctionName I_BusPartContactPersonGov ContactPersonFunctionName
ContactPersonDepartment I_BusPartContactPersonGov ContactPersonDepartment
ContactPersonDepartmentName I_BusPartContactPersonGov ContactPersonDepartmentName
ContactPersonAuthorityType I_BusPartContactPersonGov ContactPersonAuthorityType
ContactPersonVIPType I_BusPartContactPersonGov ContactPersonVIPType
ContactPersonRemarkText I_BusPartContactPersonGov ContactPersonRemarkText
PhoneNumber I_BusPartContactPersonGov PhoneNumber
PhoneNumberExtension I_BusPartContactPersonGov PhoneNumberExtension
AddressFaxNumber I_BusPartContactPersonGov AddressFaxNumber
FaxNumberExtension I_BusPartContactPersonGov FaxNumberExtension
EmailAddress I_BusPartContactPersonGov EmailAddress
BusinessPartner1 I_BusPartRelationshipGov BusinessPartner1
BusinessPartner2 I_BusPartRelationshipGov BusinessPartner2
BP1AuthorizationGroup I_BusPartRelationshipGov BP1AuthorizationGroup
BP2AuthorizationGroup I_BusPartRelationshipGov BP2AuthorizationGroup
ETag
_RelationshipGov _RelationshipGov
_ContactPersonDepartmentText _ContactPersonDepartmentText
_ContactPersonFunctionText _ContactPersonFunctionText
_BPContactPersonAuthorityText _BPContactPersonAuthorityText
_BPCntctPersnVIPIndicatorText _BPCntctPersnVIPIndicatorText
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'BP Relationship Contact Person Data - TP'
@ObjectModel.usageType.serviceQuality: #X
@ObjectModel.usageType.dataClass: #MIXED
@ObjectModel.usageType.sizeCategory: #XL
//@Search.searchable: true

@VDM.viewType: #TRANSACTIONAL
@VDM.usage.type: [ #TRANSACTIONAL_PROCESSING_SERVICE ]
define view entity I_BusPartContactPersonGovTP
  as select from           I_BusPartRelationshipGov  as _Current
    inner join             I_BusPartContactPersonGov as _ContactPersonData   on  _Current.MasterDataChangeProcess     = _ContactPersonData.MasterDataChangeProcess
                                                                             and _Current.MDChgProcessStep            = _ContactPersonData.MDChgProcessStep
                                                                             and _Current.MDChgProcessSrceSystem      = _ContactPersonData.MDChgProcessSrceSystem
                                                                             and _Current.MDChgProcessSrceObject      = _ContactPersonData.MDChgProcessSrceObject
                                                                             and _Current.BPRelshpCatIsInFwdDirection = _ContactPersonData.BPRelshpCatIsInFwdDirection
    left outer to one join tbz9                      as RelationshipCategory on _Current.RelationshipCategory = RelationshipCategory.reltyp
  association        to parent I_BusPartRelationshipGovTP as _RelationshipGov              on  $projection.MasterDataChangeProcess     = _RelationshipGov.MasterDataChangeProcess
                                                                                           and $projection.MDChgProcessSrceSystem      = _RelationshipGov.MDChgProcessSrceSystem
                                                                                           and $projection.MDChgProcessSrceObject      = _RelationshipGov.MDChgProcessSrceObject
                                                                                           and $projection.BPRelshpUUID                = _RelationshipGov.BPRelshpUUID
                                                                                           and $projection.BPRelshpCatIsInFwdDirection = _RelationshipGov.BPRelshpCatIsInFwdDirection
//  association [1..1] to I_BusPartRelshpCategoryVH         as _RelationshipCategoryForward  on  $projection.RelationshipCategory        = _RelationshipCategoryForward.RelationshipCategory

//                                                                                           and $projection.BPRelshpCatIsInFwdDirection = _RelationshipCategoryForward.BPRelshpCatIsInFwdDirection


  association [1..*] to I_ContactPersonDepartmentT        as _ContactPersonDepartmentText  on  $projection.ContactPersonDepartment = _ContactPersonDepartmentText.ContactPersonDepartment
  association [0..*] to I_ContactPersonFunctionT          as _ContactPersonFunctionText    on  $projection.ContactPersonFunction = _ContactPersonFunctionText.ContactPersonFunction
  association [1..*] to I_BPContactPersonAuthorityText    as _BPContactPersonAuthorityText on  $projection.ContactPersonAuthorityType = _BPContactPersonAuthorityText.ContactPersonAuthorityType
  association [1..*] to I_BPCntctPersnVIPIndicatorText    as _BPCntctPersnVIPIndicatorText on  $projection.ContactPersonVIPType = _BPCntctPersnVIPIndicatorText.ContactPersonVIPType

{
  key cast ( hextobin('00000000000000000000000000000000') as sysuuid_x preserving type ) as BPRelshpUUID,
  key _Current.MasterDataChangeProcess,
  key _Current.MDChgProcessSrceSystem,
  key _Current.MDChgProcessSrceObject,
  key _Current.BPRelshpCatIsInFwdDirection,
      _Current.MDChgProcessStep,
      _ContactPersonData.ContactPersonFunction,
      _ContactPersonData.ContactPersonFunctionName,
      _ContactPersonData.ContactPersonDepartment,
      _ContactPersonData.ContactPersonDepartmentName,
      _ContactPersonData.ContactPersonAuthorityType,
      _ContactPersonData.ContactPersonVIPType,
      _ContactPersonData.ContactPersonRemarkText,
      _ContactPersonData.PhoneNumber,
      _ContactPersonData.PhoneNumberExtension,
      _ContactPersonData.AddressFaxNumber,
      _ContactPersonData.FaxNumberExtension,
      _ContactPersonData.EmailAddress,
      _Current.BusinessPartner1,
      _Current.BusinessPartner2,
      _Current.BP1AuthorizationGroup,
      _Current.BP2AuthorizationGroup,
//      @ObjectModel.editableFieldFor: 'BusinessPartner2'

//      case

//        when length(_Current.BusinessPartner2) > 10

//          then case

//          when _Current._BusinessPartner2InProcess.BusinessPartner is not initial

//                   then _Current._BusinessPartner2InProcess.BusinessPartner

//               end

//          else cast (_Current.BusinessPartner2 as bu_partner )

//      end                                                                                as BusinessPartner2ForEdit,

//      case

//          when _Current._BusinessPartner2InProcess.MDChgProcessSrceObject is not initial

//          then _Current._BusinessPartner2InProcess.BusinessPartnerFullName

//          else _Current._BusinessPartner2Active.BusinessPartnerFullName

//      end                                                                                as BusinessPartner2FullName,

//      @Search.defaultSearchElement: true

//      _Current.RelationshipCategory,

//      @Semantics.booleanIndicator: true

//      case _Current.BPRelshpCatIsInFwdDirection

//        when 'X'

//        then ''

//        else 'X'

//      end                                                                                as BPRelshpCatIsInBkwdsDirection,

//      _Current.BusinessPartnerCategory,

//      @Semantics.booleanIndicator: true

//

//      cast ( '' as bu_xorga_r preserving type )                                          as BPCatOrgIsRelevantForBP2,

//      cast ( '' as bu_xpers_r preserving type )                                          as BPCatPersonIsRelevantForBP2,

//      cast ( '' as bu_xgrou_r preserving type )                                          as BPCatGroupIsRelevantForBP2,

//      cast (

//        case RelationshipCategory.xdfrel

//          when 'X' then ''

//        else 'X' end as boole_d preserving type)                                         as BPIsStandardRelshpIndIsHidden,

//      RelationshipCategory.timdp                                                         as BusPartRelshpCatTimeConstraint,

//      cast ( case

//              when RelationshipCategory.timdp is initial

//                then 'X'

//              else ''

//             end as boole_d preserving type )                                            as BPRelshpHasTimeConstraintZero,

//      cast ( case

//              when _Current.BusinessPartnerCategory = '2'

//                or _Current._BusinessPartner2InProcess.BusinessPartnerCategory = '2'

//                then ''

//              else 'X'

//             end as boole_d preserving type )                                            as BPContactPersonDetsAreHidden,

      cast ( 0 as mdc_process_update_token )                                             as ETag,
//      case

//      when _Current._BusinessPartner2InProcess.MasterDataChangeProcess is not null

//         then _Current._BusinessPartner2InProcess.MasterDataChangeProcess

//         else cast( '000000000000' as mdc_process_id )

//       end                                                                               as MDChgProcOfRelatedBP,

//      case

//        when _Current._BusinessPartner2InProcess.MasterDataChangeProcess is not null

//        then _Current._BusinessPartner2InProcess.MDChgProcessSrceSystem

//        else cast( '' as mdc_business_system )

//      end                                                                                as MDChgProcSrceSystemOfRelatedBP,

//      case

//        when _Current._BusinessPartner2InProcess.MasterDataChangeProcess is not null

//        then _Current._BusinessPartner2InProcess.MDChgProcessStep

//        else cast( '0000' as mdc_process_step_no )

//      end                                                                                as MDChgProcStepOfRelatedBP,


      _RelationshipGov,
//      _RelationshipCategoryForward,

      _ContactPersonDepartmentText,
      _ContactPersonFunctionText,
      _BPContactPersonAuthorityText,
      _BPCntctPersnVIPIndicatorText

}
where
      _Current.RelationshipCategory = 'BUR001'
  and _Current.MasterDataIsCurrent  = 'X'