C_DefectsByInspLotOrign

DDL: C_DEFECTSBYINSPLOTORIGN SQL: CDEFSBYLOTORIGN Type: view CONSUMPTION

Defects By Inspection Lot Origin View

C_DefectsByInspLotOrign is a Consumption CDS View that provides data about "Defects By Inspection Lot Origin View" in SAP S/4HANA. It reads from 1 data source (C_DefectCalcFld) and exposes 33 fields with key field Defect. It has 1 association to related views.

Data Sources (1)

SourceAliasJoin Type
C_DefectCalcFld C_DefectCalcFld from

Associations (1)

CardinalityTargetAliasCondition
[1..1] I_InspectionLot _InspLot $projection.InspectionLot = _InspLot.InspectionLot

Annotations (9)

NameValueLevelField
AbapCatalog.sqlViewName CDEFSBYLOTORIGN view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #CHECK view
EndUserText.label Defects By Inspection Lot Origin View view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #XL view
VDM.viewType #CONSUMPTION view

Fields (33)

KeyFieldSource TableSource FieldDescription
KEY Defect C_DefectCalcFld Defect
DefectCodeText C_DefectCalcFld DefectCodeText
DefectCodeGroup C_DefectCalcFld DefectCodeGroup Code Group
CreationDate C_DefectCalcFld CreationDate Time Stamp
CalculationDate C_DefectCalcFld CalculationDate
InspectionLot C_DefectCalcFld InspectionLot Inspection Lot
Material C_DefectCalcFld Material Vehicle Model
Plant C_DefectCalcFld Plant Valuation Area
Customer _InspLot Customer Sold-to Party
InspectionLotType _InspLot InspectionLotType Inspection Type
InspectionLotHasQuantity
BatchStorageLocation _InspLot BatchStorageLocation
Manufacturer _InspLot Manufacturer Manufacturer
ManufacturerPartNmbr _InspLot ManufacturerPartNmbr Mfr Part Number
MatlQualityAuthorizationGroup _InspLot MatlQualityAuthorizationGroup QM Matl Auth.
PurchasingOrganization _InspLot PurchasingOrganization Purchasing Organization
SalesOrganization _InspLot SalesOrganization Sales Organization
SoldToParty _InspLot SoldToParty Sold-to Party
Supplier _InspLot Supplier Supplier
InspectionLotOrigin Inspection Lot Origin
NumberOfDefects Defects
DefectCode C_DefectCalcFld DefectCode Damage Code
InspectionLotOriginText Inspection Lot Origin Detail
DefectCategory DefectCategory
IsBusinessPurposeCompleted IsBusinessPurposeCompleted Purpose Completed
WorkCenterTypeCode WorkCenterTypeCode Object Type
MainWorkCenterInternalID MainWorkCenterInternalID Work Center
MainWorkCenter MainWorkCenter Work Center
MainWorkCenterPlant MainWorkCenterPlant Plnt WorkCenter
Notification Notification Notification
_InspLot _InspLot
_InspectionLot _InspectionLot
_Notification _Notification

Derived SQL interpretation, reconstructed from the parsed view metadata (data sources, associations, and field mappings). SAP annotations are omitted and the structure is reformulated as SQL — this is a functional approximation, not the verbatim SAP source.

-- Derived SQL interpretation of CDS view C_DefectsByInspLotOrign.
-- Reconstructed from parsed metadata (data sources, associations, fields).
-- SAP annotations are omitted and the structure is reformulated as SQL;
-- this is a functional approximation, not the verbatim SAP source. Some join
-- conditions may be unavailable and a few CDS constructs are kept as-is.
-- SQL view name: CDEFSBYLOTORIGN

CREATE VIEW C_DefectsByInspLotOrign AS
SELECT
  C_DefectCalcFld.Defect AS Defect,
  C_DefectCalcFld.DefectCodeText AS DefectCodeText,
  C_DefectCalcFld.DefectCodeGroup AS DefectCodeGroup,
  C_DefectCalcFld.CreationDate AS CreationDate,
  C_DefectCalcFld.CalculationDate AS CalculationDate,
  C_DefectCalcFld.InspectionLot AS InspectionLot,
  C_DefectCalcFld.Material AS Material,
  C_DefectCalcFld.Plant AS Plant,
  _InspLot.Customer AS Customer,
  _InspLot.InspectionLotType AS InspectionLotType,
  cast ( _InspLot.InspectionLotHasQuantity as xfeld ) AS InspectionLotHasQuantity,
  _InspLot.BatchStorageLocation AS BatchStorageLocation,
  _InspLot.Manufacturer AS Manufacturer,
  _InspLot.ManufacturerPartNmbr AS ManufacturerPartNmbr,
  _InspLot.MatlQualityAuthorizationGroup AS MatlQualityAuthorizationGroup,
  _InspLot.PurchasingOrganization AS PurchasingOrganization,
  _InspLot.SalesOrganization AS SalesOrganization,
  _InspLot.SoldToParty AS SoldToParty,
  _InspLot.Supplier AS Supplier,
  cast (_InspLot.InspectionLotOrigin as abap.char( 2 )) AS InspectionLotOrigin,
  cast (C_DefectCalcFld.NumberOfDefects as abap.int8 ) AS NumberOfDefects,
  C_DefectCalcFld.DefectCode AS DefectCode,
  _InspLot._InspectionLotOrigin._Text[1:Language=$session.system_language].InspectionLotOriginText AS InspectionLotOriginText,
  DefectCategory,
  IsBusinessPurposeCompleted,
  WorkCenterTypeCode,
  MainWorkCenterInternalID,
  MainWorkCenter,
  MainWorkCenterPlant,
  Notification
FROM C_DefectCalcFld
LEFT OUTER JOIN I_InspectionLot AS _InspLot ON InspectionLot = _InspLot.InspectionLot  -- association [1..1]
;