I_WorkPermitStatus
Work Permit Status
I_WorkPermitStatus is a Basic CDS View that provides data about "Work Permit Status" in SAP S/4HANA. It reads from 2 data sources (I_WorkPermitBasic, jest) and exposes 10 fields with key fields WorkPermit, WorkPermitInternalID, StatusCode. It has 2 associations to related views.
Data Sources (2)
| Source | Alias | Join Type |
|---|---|---|
| I_WorkPermitBasic | I_WorkPermitBasic | inner |
| jest | jest | from |
Associations (2)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_StatusObjectStatusChange | _StatusChange | $projection.WorkPermitInternalID = _StatusChange.StatusObject and $projection.StatusCode = _StatusChange.StatusCode and $projection.StatusObjectStatusChangeNumber = _StatusChange.StatusObjectStatusChangeNumber |
| [0..1] | I_SystemStatus | _SystemStatus | $projection.StatusCode = _SystemStatus.SystemStatus |
Annotations (14)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | IWRKPMTSTATUS | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| EndUserText.label | Work Permit Status | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| ObjectModel.usageType.sizeCategory | #M | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| VDM.viewType | #BASIC | view | |
| UI.headerInfo.typeName | SystemStatus | view | |
| UI.headerInfo.typeNamePlural | System Status | view | |
| UI.headerInfo.title.type | #STANDARD | view | |
| UI.headerInfo.title.label | System Status | view |
Fields (10)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | WorkPermit | I_WorkPermitBasic | WorkPermit | |
| KEY | WorkPermitInternalID | jest | objnr | |
| KEY | StatusCode | jest | stat | |
| StatusObjectStatusChangeNumber | jest | chgnr | ||
| LastChangeDate | _StatusChange | LastChangeDate | ||
| LastChangeTime | _StatusChange | LastChangeTime | ||
| StatusIsInactive | jest | inact | ||
| StatusShortName | ||||
| SystemStatusName | ||||
| _SystemStatus | _SystemStatus |
@AbapCatalog.sqlViewName: 'IWRKPMTSTATUS'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@ClientHandling.algorithm: #SESSION_VARIABLE
@AccessControl.authorizationCheck: #NOT_REQUIRED
@EndUserText.label: 'Work Permit Status'
@ObjectModel.usageType: {serviceQuality: #C, sizeCategory: #M, dataClass: #TRANSACTIONAL}
@VDM.viewType: #BASIC
@UI: {
headerInfo: { typeName: 'SystemStatus',
typeNamePlural: 'System Status' ,
title: { type: #STANDARD, label: 'System Status'
}
},
presentationVariant: [
{
sortOrder: [{by: 'LastChangeDateTime'}, [ {direction: #ASC }] ],
visualizations: [{ type: #AS_LINEITEM}],
requestAtLeast: [ 'StatusCode' ] }
]
}
define view I_WorkPermitStatus
as select from jest
inner join I_WorkPermitBasic on I_WorkPermitBasic.WorkPermitInternalID = jest.objnr
association [0..1] to I_StatusObjectStatusChange as _StatusChange on $projection.WorkPermitInternalID = _StatusChange.StatusObject
and $projection.StatusCode = _StatusChange.StatusCode
and $projection.StatusObjectStatusChangeNumber = _StatusChange.StatusObjectStatusChangeNumber
association [0..1] to I_SystemStatus as _SystemStatus on $projection.StatusCode = _SystemStatus.SystemStatus
{
@UI.hidden: true
key I_WorkPermitBasic.WorkPermit,
@UI.hidden: true
key jest.objnr as WorkPermitInternalID,
@UI.hidden: true
@UI.lineItem: [{ position: 5, label: 'StatusCode' }]
@EndUserText:{ label: 'Status', quickInfo: 'Status'}
key jest.stat as StatusCode,
@UI.hidden: true
jest.chgnr as StatusObjectStatusChangeNumber,
@UI.hidden: true
_StatusChange.LastChangeDate,
@UI.hidden: true
_StatusChange.LastChangeTime,
@Semantics.systemDateTime.createdAt: true
cast( dats_tims_to_tstmp( _StatusChange.LastChangeDate,
_StatusChange.LastChangeTime,
abap_system_timezone( $session.client,'NULL' ),
$session.client,
'NULL' ) as timestamp ) as LastChangeDateTime,
@UI.lineItem: [{ position: 10, label: 'Inactive' }]
@EndUserText:{ label: 'Inactive', quickInfo: 'Inactive'}
@UI.hidden: true
jest.inact as StatusIsInactive,
@UI.lineItem: [{ position: 20, label: 'Status' }]
@EndUserText:{ label: 'Status', quickInfo: 'Status'}
_SystemStatus._SystemStatusText[ 1: Language = $session.system_language ].SystemStatusShortName as StatusShortName,
@UI.lineItem: [{ position: 30, label: 'Description' }]
@EndUserText:{ label: 'Text', quickInfo: 'Text'}
_SystemStatus._SystemStatusText[ 1: Language = $session.system_language ].SystemStatusName,
_SystemStatus
}
where
jest.inact = ' '
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_STATUSOBJECTSTATUSCHANGE",
"I_SYSTEMSTATUS",
"I_SYSTEMSTATUSTEXT",
"I_WORKPERMITBASIC",
"JEST"
],
"ASSOCIATED":
[
"I_STATUSOBJECTSTATUSCHANGE",
"I_SYSTEMSTATUS"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/
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