I_DefectLocationCode
Defect Location Code
I_DefectLocationCode is a Basic CDS View that provides data about "Defect Location Code" in SAP S/4HANA. It reads from 1 data source (qpcd) and exposes 6 fields with key fields DefectLocationCatalog, DefectLocationCodeGroup, DefectLocationCode. Part of development package VDM_QM_NOTIFICATION.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| qpcd | qpcd | from |
Annotations (10)
| Name | Value | Level | Field |
|---|---|---|---|
| AccessControl.authorizationCheck | #CHECK | view | |
| VDM.viewType | #BASIC | view | |
| VDM.lifecycle.contract.type | #PUBLIC_LOCAL_API | view | |
| ObjectModel.usageType.dataClass | #CUSTOMIZING | view | |
| ObjectModel.usageType.serviceQuality | #A | view | |
| ObjectModel.usageType.sizeCategory | #S | view | |
| ObjectModel.representativeKey | DefectLocationCode | view | |
| Analytics.technicalName | IDEFLOCCD | view | |
| EndUserText.label | Defect Location Code | view | |
| Metadata.ignorePropagatedAnnotations | true | view |
Fields (6)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | DefectLocationCatalog | |||
| KEY | DefectLocationCodeGroup | |||
| KEY | DefectLocationCode | |||
| _DefectLocationCatalog | _DefectLocationCatalog | |||
| _DefectLocationCodeGroup | _DefectLocationCodeGroup | |||
| _DefectLocationCodeText | _DefectLocationCodeText |
@AccessControl.authorizationCheck: #CHECK
@VDM: {
viewType:#BASIC,
lifecycle.contract.type: #PUBLIC_LOCAL_API
}
@ObjectModel:{
usageType:{
dataClass: #CUSTOMIZING,
serviceQuality: #A,
sizeCategory: #S
},
representativeKey: 'DefectLocationCode'
}
@Analytics.technicalName: 'IDEFLOCCD'
@EndUserText.label: 'Defect Location Code'
@Metadata.ignorePropagatedAnnotations: true
define view entity I_DefectLocationCode as select from qpcd
association[1..1] to I_DefectLocationCatalog as _DefectLocationCatalog on $projection.DefectLocationCatalog = _DefectLocationCatalog.DefectLocationCatalog
association[1..1] to I_DefectLocationCodeGroup as _DefectLocationCodeGroup on $projection.DefectLocationCatalog = _DefectLocationCodeGroup.DefectLocationCatalog and
$projection.DefectLocationCodeGroup = _DefectLocationCodeGroup.DefectLocationCodeGroup
association[1..*] to I_DefectLocationCodeText as _DefectLocationCodeText on $projection.DefectLocationCatalog = _DefectLocationCodeText.DefectLocationCatalog and
$projection.DefectLocationCodeGroup = _DefectLocationCodeText.DefectLocationCodeGroup and
$projection.DefectLocationCode = _DefectLocationCodeText.DefectLocationCode
{
@ObjectModel.foreignKey.association: '_DefectLocationCatalog'
key cast( katalogart as vdm_qfeocat preserving type ) as DefectLocationCatalog,
@ObjectModel.foreignKey.association: '_DefectLocationCodeGroup'
key cast( codegruppe as vdm_qfeogrp preserving type ) as DefectLocationCodeGroup,
@ObjectModel.text.association: '_DefectLocationCodeText'
key cast( code as vdm_qfeocod preserving type ) as DefectLocationCode,
// DB field has three values, but field shall be indicator
@Semantics.booleanIndicator: true
case qpcd.inaktiv
when ' ' then cast( ' ' as vdm_qm_codeisinactive preserving type )
else cast( 'X' as vdm_qm_codeisinactive preserving type )
end as CodeIsInactive,
_DefectLocationCatalog,
_DefectLocationCodeGroup,
_DefectLocationCodeText
} where
(
// katalogart = 'B' or //Object Parts
katalogart = 'E' //Defect Locations
)
and qpcd.version = '000001'
Learn More
- What Is a CDS View in SAP S/4HANA?
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- CDS View Annotations — A Complete Guide
- CDS View Field Mapping and Associations
- Understanding the SAP S/4HANA Data Model
- CDS View Extensions and Custom Fields in SAP S/4HANA
- Released APIs and Stability Contracts in SAP S/4HANA