C_Inspoperation_Object

DDL: C_INSPOPERATION_OBJECT SQL: CINSPOPERAOBJECT Type: view CONSUMPTION

Inspection Lot Operations

C_Inspoperation_Object is a Consumption CDS View that provides data about "Inspection Lot Operations" in SAP S/4HANA. It reads from 1 data source (I_InspectionOperation) and exposes 20 fields with key fields InspectionOperation, InspectionLot.

Data Sources (1)

SourceAliasJoin Type
I_InspectionOperation _Operation from

Annotations (9)

NameValueLevelField
AbapCatalog.sqlViewName CINSPOPERAOBJECT view
ClientHandling.algorithm #SESSION_VARIABLE view
AbapCatalog.compiler.compareFilter true view
VDM.viewType #CONSUMPTION view
EndUserText.label Inspection Lot Operations view
AccessControl.authorizationCheck #CHECK view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.serviceQuality #D view

Fields (20)

KeyFieldSource TableSource FieldDescription
KEY InspectionOperation I_InspectionOperation InspectionOperation
KEY InspectionLot I_InspectionOperation InspectionLot
OrderInternalBillOfOperations I_InspectionOperation OrderInternalBillOfOperations
InspPlanOperationInternalID I_InspectionOperation InspPlanOperationInternalID
WorkCenter
OperationText I_InspectionOperation OperationText
WorkCenterText
InspCharOpenCount _InspOperationAggregate InspCharOpenCount
InspCharAcceptedCount _InspOperationAggregate InspCharAcceptedCount
InspCharRejectedCount _InspOperationAggregate InspCharRejectedCount
InspCharcAcceptedSampleCount _InspOperationAggregate InspCharcAcceptedSampleCount
InspCharOpenSampleCount _InspOperationAggregate InspCharOpenSampleCount
InspCharRejectedSampleCount _InspOperationAggregate InspCharRejectedSampleCount
MaterialSampleCount _InspOperationAggregate MaterialSampleCount
InspSubsetCharcAcceptedCount _InspOperationAggregate InspSubsetCharcAcceptedCount
InspSubsetCharcRejectedCount _InspOperationAggregate InspSubsetCharcRejectedCount
InspSubsetCharcOpenCount _InspOperationAggregate InspSubsetCharcOpenCount
InspectionOperationPlant I_InspectionOperation InspectionOperationPlant
InspectionLotType
MatlQualityAuthorizationGroup
@AbapCatalog.sqlViewName: 'CINSPOPERAOBJECT'
@ClientHandling.algorithm: #SESSION_VARIABLE
@AbapCatalog.compiler.compareFilter: true
@VDM.viewType: #CONSUMPTION
@EndUserText.label: 'Inspection Lot Operations'
@AccessControl.authorizationCheck: #CHECK
@ObjectModel.usageType: {
    dataClass: #MIXED,
    sizeCategory: #L, //expected number of rows < 10.000.000

    serviceQuality: #D 
}
define view C_Inspoperation_Object 
as select from I_InspectionOperation as _Operation
    left outer to one join I_InspOperationAggregate as _InspOperationAggregate
        on _Operation.InspPlanOperationInternalID = _InspOperationAggregate.InspPlanOperationInternalID
        and _Operation.InspectionLot              = _InspOperationAggregate.InspectionLot
    left outer to one join I_InspOperationUsageDecision as _InspOperationUsageDecision
        on _Operation.InspectionLot                = _InspOperationUsageDecision.InspectionLot
        and _Operation.InspPlanOperationInternalID = _InspOperationUsageDecision.InspPlanOperationInternalID
{
   key _Operation.InspectionOperation,              
   key _Operation.InspectionLot,
   _Operation.OrderInternalBillOfOperations,
   _Operation.InspPlanOperationInternalID,
   _Operation._WorkCenter.WorkCenter,               
   _Operation.OperationText,                        
   _Operation._WorkCenter._Text[1:Language=$session.system_language].WorkCenterText,     
   _InspOperationAggregate.InspCharOpenCount,
   _InspOperationAggregate.InspCharAcceptedCount,
   _InspOperationAggregate.InspCharRejectedCount,
   _InspOperationAggregate.InspCharcAcceptedSampleCount,
   _InspOperationAggregate.InspCharOpenSampleCount,
   _InspOperationAggregate.InspCharRejectedSampleCount,
   
   _InspOperationAggregate.MaterialSampleCount,
   _InspOperationAggregate.InspSubsetCharcAcceptedCount,
   _InspOperationAggregate.InspSubsetCharcRejectedCount,
   _InspOperationAggregate.InspSubsetCharcOpenCount,

   @Consumption.hidden: true     //for DCL only

   _Operation.InspectionOperationPlant,
   @Consumption.hidden: true     //for DCL only

   _Operation._InspectionLot.InspectionLotType,
   @Consumption.hidden: true     //for DCL only

   _Operation._InspectionLot.MatlQualityAuthorizationGroup,
   
   //Check whether this operation has characteristics: when 0 no characteristic  

   case _Operation._InspectionLot.InspectionSubsetType
   when '3' then case(_InspOperationAggregate.InspCharcAcceptedSampleCount+
                      _InspOperationAggregate.InspCharOpenSampleCount+
                      _InspOperationAggregate.InspCharRejectedSampleCount)
                 when 0 then 0 else 1 end
   else case(_InspOperationAggregate.InspCharOpenCount+
             _InspOperationAggregate.InspCharAcceptedCount+
             _InspOperationAggregate.InspCharRejectedCount)
        when 0 then 0 else 1 end
   end as InspOpHasCharc,
   
   //Visible controler of sample bar: when 2 ,material sample exist 

   case _Operation._InspectionLot._InspSubsetFieldCombination.SamplingProcedureInspSubset
   when '2' then 1
   else 0 end as InspLotHasSubsets,
   
   //Logic of valuation display

   case _Operation._InspectionOperationStatus.InspectionOpIsCompletionNeeded
   when 'X' then _InspOperationUsageDecision.InspOpUsageDecisionValuation 
   else case _Operation._InspectionLot.InspectionSubsetType       
        when '3' then case _InspOperationAggregate.InspCharRejectedSampleCount //Operation has samples

                      when 0 then case _InspOperationAggregate.InspCharcAcceptedSampleCount
                                  when 0 then '' 
                                  else case (_InspOperationAggregate.InspCharOpenSampleCount+
                                             _InspOperationAggregate.InspCharRejectedSampleCount)
                                       when 0 then 'A' else '' end
                                  end
                      else 'R' 
                      end     
        else case _InspOperationAggregate.InspCharRejectedCount //Operation has no sample    

             when 0 then case _InspOperationAggregate.InspCharAcceptedCount
                         when 0 then '' 
                         else case (_InspOperationAggregate.InspCharOpenCount+
                                    _InspOperationAggregate.InspCharRejectedCount) 
                              when 0 then 'A' else '' end
                         end
             else 'R' 
             end 
        end      
   end as InspOpUsageDecisionValuation
}                                                                           
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
 /*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_INSPECTIONLOT",
"I_INSPECTIONOPERATION",
"I_INSPECTIONOPERATIONSTATUS",
"I_INSPOPERATIONAGGREGATE",
"I_INSPOPERATIONUSAGEDECISION",
"I_INSPSUBSETFIELDCOMBINATION",
"I_WORKCENTER",
"I_WORKCENTERTEXT"
],
"ASSOCIATED":
[],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/