Authorization

In order to use the analysis, you need the rights to access the statistic "Faults".

Technical information

The "Faults" evaluation uses the following SQL query to prepare the data:

PMS distribution fault codes by machine type
declare @INNO_USER_LANG int = :INNO_USER_LANG;
declare @INNO_USER varchar(12) = :INNO_USER;
declare @DATE_FROM date = :date_from;
declare @DATE_TO date = :date_to;
 
 
with stoerungen as
(
select
distinct(stoerung_code) stoerung_code,
stoerung_code + ' - ' + stoerung_text as code_text
from
FACT_TICKET_DLZ p
 
where
cast(p.START_ZEIT as date) >= @DATE_FROM and cast(p.START_ZEIT as date) <= @DATE_TO
and not (stoerung_code is null or stoerung_code = '')
and (:maschtyp_ISNULL = 1 OR p.maschnr in (select m.maschnr from mapark m where m.maschtyp in (:maschtyp)))
 
)
 
,stoerungen_offen as
(
select
count(p.stoerung_code) c_offen,
stoerung_code + ' - ' + stoerung_text as code_text,
'red' as color_offen
 
from
FACT_TICKET_DLZ p
 
where
cast(p.START_ZEIT as date) >= @DATE_FROM and cast(p.START_ZEIT as date) <= @DATE_TO
and not (stoerung_code is null or stoerung_code = '')
and p.AKTIV = 1
and (:maschtyp_ISNULL = 1 OR p.maschnr in (select m.maschnr from mapark m where m.maschtyp in (:maschtyp)))
 
group by
p.stoerung_code,
p.stoerung_text
)
,stoerungen_geschlossen as
(
select
count(p.stoerung_code) c_geschlossen,
stoerung_code + ' - ' + stoerung_text as code_text,
'green' as color_geschlossen
 
from
FACT_TICKET_DLZ p
 
where
cast(p.START_ZEIT as date) >= @DATE_FROM and cast(p.START_ZEIT as date) <= @DATE_TO
and not (stoerung_code is null or stoerung_code = '')
and p.AKTIV = 0
and (:maschtyp_ISNULL = 1 OR p.maschnr in (select m.maschnr from mapark m where m.maschtyp in (:maschtyp)))
 
group by
p.stoerung_code,
p.stoerung_text
)
 
select
s.stoerung_code,
s.code_text,
so.c_offen,
so.color_offen,
sg.c_geschlossen,
sg.color_geschlossen
from
stoerungen s,
stoerungen_offen so,
stoerungen_geschlossen sg
where
so.code_text = s.code_text
and sg.code_text = s.code_text
 
order by
so.c_offen + sg.c_geschlossen desc

The interface of this statistic is stored with the following data set in the table "Statistic_UI":

INSERT faults
INSERT INTO STATISTIC_UI (ID, NAME, STATISTIC_CONFIGURATION, STATISTIC_CONTROLLER, CATEGORY_ID, DELETED, DESCRIPTION, IS_INTERNAL, OVERRIDDEN_BY)
VALUES ('{13540FB3-149E-4ED1-86F9-0A7BD09B06A8}6', 'Störungen', '{
"type": "STATISTIK",
"rows": [
{
"type": "ROW",
"rowItems": [
{
"type": "CHART",
"width": "12",
"uid": "452e9563-0248-4ac4-9ec1-c393f8340369",
"dataUrl": "api/dynamicapi/{205C8FC4-03D9-4C75-9634-CE9A6C9B7E72}16/GetData",
"chartSettings": {
"theme": "bootstrap",
"series": [
{
"type": "bar",
"field": "C_OFFEN",
"colorField": "COLOR_OFFEN",
"categoryField": "",
"name": "",
"labels": {
"visible": true
},
"stack": {
"group": "STACK_1"
}
},
{
"type": "bar",
"field": "C_GESCHLOSSEN",
"color": "",
"colorField": "COLOR_GESCHLOSSEN",
"categoryField": "",
"name": "",
"labels": {
"visible": true
},
"stack": {
"group": "STACK_1"
}
}
],
"categoryAxis": {
"field": "CODE_TEXT"
},
"valueAxis": null
},
"titel": "{{{Statistik.VerteilungderStörungscodes}}}",
"height": "500",
"pageSize": "",
"drilldown": {
"statisticId": "{13540FB3-149E-4ED1-86F9-0A7BD09B06A8}18",
"sourceField": "",
"destField": "",
"hideInputControls": "false"
},
"dataSource": {
"dataUrl": "api/dynamicapi/{205C8FC4-03D9-4C75-9634-CE9A6C9B7E72}16/GetData",
"_Object_Type": "sql"
}
}
],
"uid": "e0db9fbf-1261-46c5-b27b-13769347593a"
}
],
"parameters": [
{
"type": "DATE",
"width": "7",
"uid": "961b3f3b-7fda-4630-b1cf-c68edd9c450e",
"name": "date_from",
"label": "{{{Standard.Von}}}"
},
{
"type": "DATE",
"width": "7",
"uid": "c0afe52f-e152-4f8a-bf1c-80ae3dc366f8",
"name": "date_to",
"label": "{{{Standard.Bis}}}"
},
{
"type": "MULTISELECT",
"width": "12",
"uid": "bd94eff0-b498-4b50-b45d-4db42f3f43ea",
"label": "{{{Field.Maschine.maogrnr}}}",
"name": "maschtyp",
"dataUrl": "api/dynamicapi/{205C8FC4-03D9-4C75-9634-CE9A6C9B7E72}21/GetData",
"keyField": "MASCHTYP",
"valueField": "MASCHTYP"
}
],
"settings": {
"type": "SETTINGS"
}
}', '
var controller={};
 
controller.getInitialValues = function(paramsFromStorage){
 
if (paramsFromStorage) {
return paramsFromStorage;
}
 
var Jahr = new Date().getFullYear();
return {
date_from: ''01.01.'' + Jahr,
date_to: ''31.12.'' + Jahr
};
 
}
 
controller;
', 4, 0, 'Anzahl der Tickets, denen im gewählten Zeitraum ein Störungscode zugewiesen worden ist.
<br>
Rot / Grün: Offene / Geschlossene Tickets.
<br><br>
Durch Klick auf einen der Balken werden per Drilldown die Ursachen zum jeweiligen Störungscode aufgeschlüsselt.
<br><br>
Filter:
<br>
<ul><li>Start - Ende<li>Maschinentyp</ul>', 1, NULL);