I_MASSMAINTCAPAREAOFRESPY
Work Center Capacity AOR
I_MASSMAINTCAPAREAOFRESPY is a CDS View in S/4HANA. Work Center Capacity AOR. It contains 1 fields. 3 CDS views read from this table.
CDS Views using this table (3)
| View | Type | Join | VDM | Description |
|---|---|---|---|---|
| I_BillOfOpsOpWrkCtrGrouping | view_entity | inner | COMPOSITE | Grpg of WrkCntr on BillOfOps Group Type |
| I_MfgBOOMatlAssgmtWrkCtrGrpg | view_entity | inner | COMPOSITE | Material Assignment Work Center Grouping |
| R_WorkCenterCapacityListTP | view_entity | inner | TRANSACTIONAL | Work Center Capacity List |
Fields (1)
| Key | Field | CDS Fields | Used in Views |
|---|---|---|---|
| KEY | AreaOfResponsibility | AreaOfResponsibility | 3 |
@AbapCatalog.viewEnhancementCategory: [#NONE]
@AccessControl.authorizationCheck: #NOT_REQUIRED
@EndUserText.label: 'Work Center Capacity AOR'
@VDM.viewType: #COMPOSITE
@Metadata.ignorePropagatedAnnotations: true
@ObjectModel.usageType:{
serviceQuality: #X,
sizeCategory: #S,
dataClass: #MIXED
}
define view entity I_MassMaintCapAreaOfRespy
as select from I_WorkCenterCapacity as _crca
inner join I_WorkCenterGroupTreeAggrgn as _wkcgrp on _wkcgrp.WorkCenterGroupHierarchyNode = _crca.WorkCenterInternalID
and _wkcgrp.WrkCtrGroupHierarchyNodeType = 'A'
inner join I_WorkCtrGrpCapByAreaOfRespy as _wkcgrpAOR on _wkcgrpAOR.UserID = $session.user
and _wkcgrpAOR.Plant = _wkcgrp.Plant
and _wkcgrpAOR.WorkCenterGroupInternalID = _wkcgrp.WrkCtrGroupHierarchyRootNode //HierarchyParentNode
and _wkcgrpAOR.WorkCenterGroupTypeCode = 'G'
inner join I_MassMaintCapAreaOfRespyPref as _AORPref on _AORPref.AreaOfResponsibility = 'WKCGRP'
and _AORPref.AreaOfRespyIsMaintained = 'X'
and _AORPref.AreaOfRespyPreferencePatternID = 'MMWKC'
{
key _crca.CapacityInternalID as CapacityInternalID,
key cast( 'WKCGRP' as pp_aor_id ) as AreaOfResponsibility,
max( _crca.WorkCenterInternalID ) as WorkCenterInternalID
}
group by
_crca.CapacityInternalID
union select from I_WorkCenterCapacity as _crca
inner join I_MassMaintCapAreaOfRespyPref as _AORPref on _AORPref.AreaOfResponsibility = 'PMRP'
and _AORPref.AreaOfRespyIsMaintained = 'X'
and _AORPref.AreaOfRespyPreferencePatternID = 'MMWKC'
inner join I_SDMAreaOfResponsibility as _SDMAreaOfResponsibility on _SDMAreaOfResponsibility.UserID = $session.user
and _SDMAreaOfResponsibility.Plant = _crca.Plant
inner join P_AreaOfRespyBOOSqncOpAssgmt as _OperationActTasks on _OperationActTasks.WorkCenterInternalID = _crca.WorkCenterInternalID
and _OperationActTasks.WorkCenterTypeCode = _crca.WorkCenterTypeCode
inner join P_WrkCtrCapAreaOfRespyHrzn as _Horizon on _Horizon.HorizonStartDate <= $session.system_date
and _Horizon.HorizonEndDate >= $session.system_date
inner join I_BasicProdnVersionWorkCtrCap as _ProductionVersions on _ProductionVersions.BillOfOperationsType = _OperationActTasks.BillOfOperationsType
and _ProductionVersions.BillOfOperationsGroup = _OperationActTasks.BillOfOperationsGroup
// and _ProductionVersions.BillOfOperationsVariant = _OperationActivities.BillOfOperationsVariant
and _ProductionVersions.BillOfOperationsVariant = _OperationActTasks.BillOfOperationsVariant
// and _ProductionVersions.Plant = _OperationActTasks.Plant
and (
_ProductionVersions.ValidityStartDate <= $session.system_date
or _ProductionVersions.ValidityStartDate between $session.system_date and _Horizon.HorizonEndDate
)
and (
_ProductionVersions.ValidityEndDate >= $session.system_date
)
and _ProductionVersions.ProductionVersionLock = ''
and (
_ProductionVersions.BillOfOperationsType = 'N'
or _ProductionVersions.BillOfOperationsType = '2'
)
inner join P_MaterialPlantAreaOfRespy as _Material on _Material.Material = _ProductionVersions.Material
and _Material.Plant = _ProductionVersions.Plant
{
key _crca.CapacityInternalID as CapacityInternalID,
key cast( 'PMRP' as pp_aor_id ) as AreaOfResponsibility,
max( _crca.WorkCenterInternalID ) as WorkCenterInternalID
}
group by
_crca.CapacityInternalID
union select from I_WorkCenterCapacity as _crca
inner join P_WrkCtrPersnRespAORList as _wkcrespAOR on _wkcrespAOR.Plant = _crca.Plant
and _wkcrespAOR.WorkCenterResponsible = _crca.WorkCenterResponsible
and _wkcrespAOR.PersnRespAORIsAssigned = 1
inner join I_MassMaintCapAreaOfRespyPref as _AORPref on _AORPref.AreaOfResponsibility = 'WKCRESP'
and _AORPref.AreaOfRespyIsMaintained = 'X'
and _AORPref.AreaOfRespyPreferencePatternID = 'MMWKC'
{
key _crca.CapacityInternalID as CapacityInternalID,
key cast( 'WKCRESP' as pp_aor_id ) as AreaOfResponsibility,
max( _crca.WorkCenterInternalID ) as WorkCenterInternalID
}
group by
_crca.CapacityInternalID