I_MAINTENANCEORDEROPERATION
Maintenance Order Operation
I_MAINTENANCEORDEROPERATION is a CDS View in S/4HANA. Maintenance Order Operation. It contains 62 fields. 11 CDS views read from this table.
CDS Views using this table (11)
| View | Type | Join | VDM | Description |
|---|---|---|---|---|
| C_MalfunctionReportWorkItem | view | from | CONSUMPTION | Malfunction Report Work Items |
| C_ObjPgMaintOrderOpAggrgData | view | from | CONSUMPTION | Maintenance Order Operation Aggregate Data |
| C_WorkPermitOrderOperationVH | view | from | CONSUMPTION | Work Permit Order Operations |
| I_DFS_MaintOrdAndOpTechSts | view | from | COMPOSITE | Interface view for TStat of Ord and Op |
| I_MaintOrderHasOpenMainWork | view | from | COMPOSITE | I_MaintOrderHasOpenMainWork |
| I_MaintOrderOperTechObj | view | from | COMPOSITE | MaintOrder Operation w/ Technical Object |
| I_MaintOrdOpStdVH | view | from | COMPOSITE | Maintenance Order Operation |
| I_WrkPmtMaintOperation | view | from | BASIC | Work Permit Maintenance Order Operation |
| P_MaintenanceJobAndWorkItem | view | left_outer | COMPOSITE | |
| P_RSHOperationExplicitRelation | view | inner | CONSUMPTION | Operations with explicit Relations |
| P_RSHOperationsWOExplicitRelat | view | from | CONSUMPTION | Operations without explicit Relations |
Fields (62)
| Key | Field | CDS Fields | Used in Views |
|---|---|---|---|
| KEY | MaintenanceOrder | MaintenanceOrder,PredecessorOrder,SuccessorOrder | 7 |
| KEY | MaintenanceOrderOperation | MaintenanceOrderOperation,PredecessorOperation,SuccessorOperation | 4 |
| KEY | MaintOrderOperationCounter | MaintOrderOperationCounter | 4 |
| KEY | MaintOrderOperationInternalID | MaintOrderOperationInternalID,StatusObject | 4 |
| _Assembly | _Assembly | 1 | |
| _Language | _Language | 1 | |
| _MaintenanceOrder | _MaintenanceOrder | 2 | |
| _MaintOperationExecStageCode | _MaintOperationExecStageCode | 1 | |
| _OperationCalculationControl | _OperationCalculationControl | 1 | |
| _OperationControlKey | _OperationControlKey | 1 | |
| _OperationHasLongText | _OperationHasLongText | 1 | |
| _OperationPlanningValues | _OperationPlanningValues | 1 | |
| _OperationSystemCondition | _OperationSystemCondition | 1 | |
| _OpExternalProcessingCurrency | _OpExternalProcessingCurrency | 1 | |
| _PersonResponsible | _PersonResponsible | 1 | |
| _Plant | _Plant | 2 | |
| _StatusObject | _StatusObject | 1 | |
| _Supplier | _Supplier | 1 | |
| _WorkCenter | _WorkCenter | 3 | |
| Assembly | Assembly | 1 | |
| CapacityRequirement | CapacityRequirement | 1 | |
| CapacityRequirementItem | CapacityRequirementItem | 1 | |
| CostCtrActivityType | CostCtrActivityType | 1 | |
| CostElement | CostElement | 1 | |
| DfsMaintOrdOpObjectNmbr | DfsMaintOrdOpObjectNmbr | 1 | |
| Equipment | Equipment | 1 | |
| FunctionalLocation | FunctionalLocation | 1 | |
| Language | Language | 1 | |
| MaintOperationalChecklistType | MaintOperationalChecklistType | 1 | |
| MaintOperationExecStageCode | MaintOperationExecStageCode | 1 | |
| MaintOrderRoutingNumber | MaintOrderRoutingNumber | 4 | |
| MaintOrdOpProcessPhaseCode | MaintOrdOpProcessPhaseCode | 1 | |
| MaintOrdOpProcessSubPhaseCode | MaintOrdOpProcessSubPhaseCode | 1 | |
| MaterialGroup | MaterialGroup | 1 | |
| NumberOfCapacities | NumberOfCapacities | 1 | |
| OperationCalculationControl | OperationCalculationControl | 1 | |
| OperationControlKey | OperationControlKey | 1 | |
| OperationDescription | OperationDescription | 3 | |
| OperationGoodsRecipientName | OperationGoodsRecipientName | 1 | |
| OperationHasLongText | OperationHasLongText | 1 | |
| OperationPersonResponsible | OperationPersonResponsible,PersonResponsible | 3 | |
| OperationPurchasingInfoRecord | OperationPurchasingInfoRecord | 1 | |
| OperationPurgInfoRecdSearchTxt | OperationPurgInfoRecdSearchTxt | 1 | |
| OperationRequisitionerName | OperationRequisitionerName | 1 | |
| OperationSupplier | OperationSupplier | 1 | |
| OperationSystemCondition | OperationSystemCondition | 1 | |
| OperationTrackingNumber | OperationTrackingNumber | 1 | |
| OperationUnloadingPointName | OperationUnloadingPointName | 1 | |
| OperationWorkCenterInternalID | OperationWorkCenterInternalID | 3 | |
| OperationWorkCenterTypeCode | OperationWorkCenterTypeCode | 3 | |
| OperationWorkPercent | OperationWorkPercent | 1 | |
| OpExternalProcessingCurrency | OpExternalProcessingCurrency | 1 | |
| OpExternalProcessingPrice | OpExternalProcessingPrice | 1 | |
| OpExternalProcessingPriceUnit | OpExternalProcessingPriceUnit | 1 | |
| OpPurchaseOutlineAgreement | OpPurchaseOutlineAgreement | 1 | |
| OpPurchaseOutlineAgreementItem | OpPurchaseOutlineAgreementItem | 1 | |
| Plant | Plant | 4 | |
| PurchaseRequisition | PurchaseRequisition | 1 | |
| PurchaseRequisitionItem | PurchaseRequisitionItem | 1 | |
| PurchasingGroup | PurchasingGroup | 1 | |
| PurchasingOrganization | PurchasingOrganization | 1 | |
| ReqgCostCenterControllingArea | ReqgCostCenterControllingArea | 1 |
@AbapCatalog.sqlViewName: 'IMAINTORDOP'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #CHECK
@AccessControl.personalData.blocking: #('TRANSACTIONAL_DATA')
@EndUserText.label: 'Maintenance Order Operation'
@VDM.viewType: #BASIC
@ObjectModel.representativeKey: 'MaintenanceOrderOperation'
@ObjectModel.semanticKey: [ 'MaintenanceOrder', 'MaintenanceOrderOperation' ]
@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType.dataClass: #TRANSACTIONAL
@ObjectModel.usageType.serviceQuality: #A
@ObjectModel.usageType.sizeCategory: #XL
@AccessControl.privilegedAssociations: ['_StatusObjectActiveStatus']
define view I_MaintenanceOrderOperation
as select from afvc as afvc
// inner join afvv as afvv on afvc.aufpl = afvv.aufpl
// and afvc.aplzl = afvv.aplzl
// inner join afvu as afvu on afvc.aufpl = afvu.aufpl
// and afvc.aplzl = afvu.aplzl
left outer to one join afko as afko on afvc.aufpl = afko.aufpl
left outer to one join aufk as aufk on aufk.aufnr = afko.aufnr
//inner join afih on afko.aufnr = afih.aufnr -- covered with plnaw = 'I'
// suboperations are also in AFVC. To find out which main operation number they belong to, need to self-join -- unused
// left outer join afvc as afvc_top on afvc_top.aufpl = afvc.aufpl
// and afvc_top.aplzl = afvc.sumnr
association [1..1] to I_MaintOrderOperPlanningValues as _OperationPlanningValues on $projection.MaintOrderRoutingNumber = _OperationPlanningValues.MaintOrderRoutingNumber
and $projection.MaintOrderOperationCounter = _OperationPlanningValues.MaintOrderOperationCounter
association [0..1] to I_MaintenanceOrder as _MaintenanceOrder on $projection.MaintenanceOrder = _MaintenanceOrder.MaintenanceOrder
association [0..*] to I_MaintenanceOrderComponent_2 as _MaintenanceOrderComponent on $projection.MaintenanceOrder = _MaintenanceOrderComponent.MaintenanceOrder
and $projection.MaintOrderRoutingNumber = _MaintenanceOrderComponent.MaintOrderRoutingNumber
and $projection.MaintOrderOperationCounter = _MaintenanceOrderComponent.MaintOrderOperationCounter
association [0..*] to I_MaintenanceOrderSubOperation as _MaintenanceOrderSubOperation on $projection.MaintenanceOrder = _MaintenanceOrderSubOperation.MaintenanceOrder
and $projection.MaintenanceOrderOperation = _MaintenanceOrderSubOperation.MaintenanceOrderOperation
association [0..1] to I_WorkCenter as _WorkCenter on $projection.OperationWorkCenterInternalID = _WorkCenter.WorkCenterInternalID
and $projection.OperationWorkCenterTypeCode = _WorkCenter.WorkCenterTypeCode
association [0..1] to I_Currency as _OpExternalProcessingCurrency on $projection.OpExternalProcessingCurrency = _OpExternalProcessingCurrency.Currency
association [0..1] to I_StatusObject as _StatusObject on $projection.MaintOrderOperationInternalID = _StatusObject.StatusObject
association [0..1] to I_OperationControlProfile as _OperationControlKey on $projection.OperationControlKey = _OperationControlKey.OperationControlProfile
association [0..1] to I_MaintOperationSystCondition as _OperationSystemCondition on $projection.OperationSystemCondition = _OperationSystemCondition.OperationSystemCondition
association [0..1] to I_Plant as _Plant on $projection.Plant = _Plant.Plant
association [0..1] to I_OperationCalculationControl as _OperationCalculationControl on $projection.OperationCalculationControl = _OperationCalculationControl.OperationCalculationControl
association [0..1] to I_Material as _Assembly on $projection.Assembly = _Assembly.Material
association [0..1] to I_Language as _Language on $projection.Language = _Language.Language
association [0..1] to I_Indicator as _OperationHasLongText on $projection.OperationHasLongText = _OperationHasLongText.IndicatorValue
association [0..*] to I_StatusObjectActiveStatus as _StatusObjectActiveStatus on $projection.MaintOrderOperationInternalID = _StatusObjectActiveStatus.StatusObject
association [0..1] to I_Supplier as _Supplier on $projection.OperationSupplier = _Supplier.Supplier
association [0..1] to I_Equipment as _Equipment on $projection.Equipment = _Equipment.Equipment
association [0..1] to I_FunctionalLocation as _FunctionalLocation on $projection.FunctionalLocation = _FunctionalLocation.FunctionalLocation
--association [0..1] to I_Employment as _PersonResponsible on $projection.OperationPersonResponsible = _PersonResponsible.EmploymentInternalID
association [0..1] to I_PersonWorkAgreement_1 as _PersonResponsible on $projection.OperationPersonResponsible = _PersonResponsible.PersonWorkAgreement
association [0..1] to I_MaintenanceOrderConfirmation as _MaintenanceOrderConf on $projection.MaintOrderConfirmation = _MaintenanceOrderConf.MaintOrderConf
and $projection.MaintOrderConfCntrValue = _MaintenanceOrderConf.MaintOrderConfCntrValue
association [0..*] to I_OrderProdnResourceTool as _MaintOrderProdnRsceTool on _MaintOrderProdnRsceTool.OrderInternalBillOfOperations = $projection.MaintOrderRoutingNumber
and _MaintOrderProdnRsceTool.OrderIntBillOfOperationsItem = $projection.MaintOrderOperationCounter
association [0..*] to I_CostCenterActivityTypeText as _CostCenterActivityTypeText on $projection.ControllingArea = _CostCenterActivityTypeText.ControllingArea
and $projection.CostCtrActivityType = _CostCenterActivityTypeText.CostCtrActivityType
association [0..1] to I_PMContactCardEmployee as _PMContactEmployee on $projection.OperationPersonResponsible = _PMContactEmployee.PersonnelNumber
association [0..1] to I_WorkAssignment as _WorkAssignment on $projection.OperationPersonResponsible = _WorkAssignment.WorkAssignment
association [1..1] to I_MaintOperationExecStageCode as _MaintOperationExecStageCode on $projection.MaintOperationExecStageCode = _MaintOperationExecStageCode.MaintOperationExecStageCode
association [0..1] to I_EAMProcessPhase as _EAMProcessPhase on $projection.MaintOrdOpProcessPhaseCode = _EAMProcessPhase.EAMProcessPhaseCode
association [0..1] to I_EAMProcessSubPhase as _EAMProcessSubPhase on $projection.MaintOrdOpProcessSubPhaseCode = _EAMProcessSubPhase.EAMProcessSubPhaseCode
{
//--[ GENERATED:012:GFBfhxvv7kY4nH9{xKJeWG
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_MaintenanceOrderStdVH',
element: 'MaintenanceOrder' }
}]
// ]--GENERATED
@ObjectModel.foreignKey.association: '_MaintenanceOrder'
key afko.aufnr as MaintenanceOrder,
@EndUserText.label: 'Operation'
@ObjectModel.text.element: ['OperationDescription']
key afvc.vornr as MaintenanceOrderOperation,
'0000' as MaintenanceOrderSubOperation,
afvc.aufpl as MaintOrderRoutingNumber,
afvc.aplzl as MaintOrderOperationCounter,
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_PlantStdVH',
element: 'Plant' }
}]
@ObjectModel.foreignKey.association: '_Plant'
afvc.werks as Plant,
'A' as OperationWorkCenterTypeCode,
afvc.arbid as OperationWorkCenterInternalID,
@ObjectModel.foreignKey.association: '_OperationControlKey'
afvc.steus as OperationControlKey,
@Semantics.text
afvc.ltxa1 as OperationDescription,
afvc.ktsch as OperationStandardTextCode,
@ObjectModel.foreignKey.association: '_Language'
cast(afvc.txtsp as spras) as Language,
afvc.loanz as NumberOfTimeTickets,
// afvc.loart as WageType,
// afvc.qualf as Suitability,
// afvc.logrp as WageGroup,
afvc.sortl as OperationPurgInfoRecdSearchTxt,
//--[ GENERATED:012:GFBfhxvv7kY4nH9{xKJeWG
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_Supplier_VH',
element: 'Supplier' }
}]
// ]--GENERATED
@ObjectModel.foreignKey.association: '_Supplier'
afvc.lifnr as OperationSupplier,
// @Semantics.quantity.unitOfMeasure: 'OperationBaseUnitOfMeasure'
// afvv.bmsch as OperationQuantity,
// @Semantics.unitOfMeasure: true
// afvv.meinh as OperationBaseUnitOfMeasure,
@Semantics.amount.currencyCode: 'OpExternalProcessingCurrency'
@DefaultAggregation: #NONE
afvc.preis as OpExternalProcessingPrice,
afvc.peinh as OpExternalProcessingPriceUnit,
afvc.sakto as CostElement,
@ObjectModel.foreignKey.association: '_OpExternalProcessingCurrency'
@Semantics.currencyCode: true
afvc.waers as OpExternalProcessingCurrency,
afvc.infnr as OperationPurchasingInfoRecord,
afvc.ekorg as PurchasingOrganization,
afvc.ekgrp as PurchasingGroup,
afvc.matkl as MaterialGroup,
cast (afvc.ebeln as konnr) as OpPurchaseOutlineAgreement,
cast (afvc.ebelp as ktpnr) as OpPurchaseOutlineAgreementItem,
afvc.afnam as OperationRequisitionerName,
afvc.bednr as OperationTrackingNumber,
@DefaultAggregation: #NONE
afvc.anzzl as NumberOfCapacities,
afvc.prznt as OperationWorkPercent,
afvc.indet as OperationCalculationControl,
afvc.larnt as ActivityType,
afvc.anlzu as OperationSystemCondition,
//afvc.vertl as DistrCapReqmts,
afvc.wempf as OperationGoodsRecipientName,
afvc.ablad as OperationUnloadingPointName,
//--[ GENERATED:012:GFBfhxvv7kY4nH9{xKJeWG
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_PersWrkAgrmtSrchHelp',
element: 'PersonWorkAgreement' }
}]
// ]--GENERATED
@ObjectModel.foreignKey.association: '_PersonResponsible'
afvc.pernr as OperationPersonResponsible,
//afvc.fordn as FrameworkOrder,
//afvc.fordp as ItemoOfFrameworkOrder,
//afvv.plifz as PlannedDeliveryTimeInDays,
//@Semantics.quantity.unitOfMeasure: 'NormalDurationUnit'
//afvv.dauno as NormalDurationOfActivity,
//@Semantics.unitOfMeasure: true
//afvv.daune as NormalDurationUnit,
//afvv.einsa as TypeConstraintStartDate,
//afvv.einse as TypeConstraintFinishDate,
//@Semantics.quantity.unitOfMeasure: 'UnitForWork'
//afvv.arbei as WorkInvolvedInActivity,
// @Semantics.unitOfMeasure: true
// afvv.arbeh as UnitForWork,
// afvv.ntanf as ConstraintActivityStartDateBas,
// afvv.ntanz as ConstraintActivityStartTimeBas,
// afvv.ntend as ConstraintActivityEndDateBas,
// afvv.ntenz as ConstraintActivityEndTimeBas,
// afvv.aufkt as ExecutionFactor,
// 'Inspection Rounds'-related fields
afvc.equnr as Equipment,
afvc.tplnr as FunctionalLocation, // <-- This is in internal labelling!
// afvc.frdlb as ExtProcOperationSubcontracting,
//afvu.ilart_op as MaintenanceActivityType,
afvc.gsber as BusinessArea,
//afvc.projn as WBSElement,
afvc.prctr as ProfitCenter,
afvc.kalsm as CostingSheet,
// afvc.zschl as Overheadkey,
afvc.txjcd as TaxJurisdiction,
//afvc.scope as ObjectClass,
afvc.func_area as FunctionalArea,
// @Semantics.quantity.unitOfMeasure: 'UnitForOffsetToStart'
// afvv.offstb as OffsetToSubOperationStart,
// @Semantics.unitOfMeasure: true
// afvv.ehoffb as UnitForOffsetToStart,
// @Semantics.quantity.unitOfMeasure: 'UnitForOffsetToFinish'
// afvv.offste as OffsetToSubOperationFinish,
// @Semantics.unitOfMeasure: true
// afvv.ehoffe as UnitForOffsetToFinish,
//--[ GENERATED:012:GFBfhxvv7kY4nH9{xKJeWG
@Consumption.valueHelpDefinition: [
{ entity: { name: 'I_MaterialStdVH',
element: 'Material' }
}]
// ]--GENERATED
@ObjectModel.foreignKey.association: '_Assembly'
afvc.istru as Assembly, //long one - 40 char
// afvc.fldlogsdelivisheldonshore as HoldOnShore,
@ObjectModel.foreignKey.association: '_MaintOperationExecStageCode'
cast( afvc.maintopexecutionphasecode as eam_premainpost_cds preserving type ) as MaintOperationExecStageCode,
afvc.larnt as CostCtrActivityType,
afvc.anfkokrs as ReqgCostCenterControllingArea,
afvc.bedid as CapacityRequirement,
afvc.bedzl as CapacityRequirementItem,
afvc.banfn as PurchaseRequisition,
afvc.objnr as MaintOrderOperationInternalID,
afvc.bnfpo as PurchaseRequisitionItem,
afvc.rueck as MaintOrderConfirmation,
afvc.mlstn as OperationMilestoneUsageCode,
afvc.rmzhl as MaintOrderConfCntrValue,
@ObjectModel.foreignKey.association: '_OperationHasLongText'
cast (
case afvc.txtsp
when '' then ''
else 'X'
end as xfeld ) as OperationHasLongText,
-- needed for some associations, e.g. activity type
aufk.kokrs as ControllingArea,
@ObjectModel.foreignKey.association: '_EAMProcessPhase'
afvc.maintordopprocessphasecode as MaintOrdOpProcessPhaseCode,
@ObjectModel.foreignKey.association: '_EAMProcessSubPhase'
afvc.maintordopprocesssubphasecode as MaintOrdOpProcessSubPhaseCode,
afvc.cl_type as MaintOperationalChecklistType,
// associations :
_MaintenanceOrderComponent,
_MaintenanceOrderSubOperation,
_MaintenanceOrder,
_StatusObject,
_OpExternalProcessingCurrency,
_OperationPlanningValues,
_WorkCenter,
_OperationControlKey,
_OperationSystemCondition,
_Plant,
_OperationCalculationControl,
_Assembly,
_Language,
_OperationHasLongText,
_StatusObjectActiveStatus,
_Supplier,
_PersonResponsible,
_FunctionalLocation,
_Equipment,
_MaintenanceOrderConf,
_MaintOrderProdnRsceTool,
_CostCenterActivityTypeText,
_PMContactEmployee,
_WorkAssignment,
_MaintOperationExecStageCode,
_EAMProcessPhase,
_EAMProcessSubPhase
}
where
afvc.sumnr = '00000000'
and afko.plnaw = 'I'
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"AFKO",
"AFVC",
"AUFK"
],
"ASSOCIATED":
[
"I_COSTCENTERACTIVITYTYPETEXT",
"I_CURRENCY",
"I_EAMPROCESSPHASE",
"I_EAMPROCESSSUBPHASE",
"I_EQUIPMENT",
"I_FUNCTIONALLOCATION",
"I_INDICATOR",
"I_LANGUAGE",
"I_MAINTENANCEORDER",
"I_MAINTENANCEORDERCOMPONENT_2",
"I_MAINTENANCEORDERCONFIRMATION",
"I_MAINTENANCEORDERSUBOPERATION",
"I_MAINTOPERATIONEXECSTAGECODE",
"I_MAINTOPERATIONSYSTCONDITION",
"I_MAINTORDEROPERPLANNINGVALUES",
"I_MATERIAL",
"I_OPERATIONCALCULATIONCONTROL",
"I_OPERATIONCONTROLPROFILE",
"I_ORDERPRODNRESOURCETOOL",
"I_PERSONWORKAGREEMENT_1",
"I_PLANT",
"I_PMCONTACTCARDEMPLOYEE",
"I_STATUSOBJECT",
"I_STATUSOBJECTACTIVESTATUS",
"I_SUPPLIER",
"I_WORKASSIGNMENT",
"I_WORKCENTER"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/