Reuse the Context Information Template |
Scroll Previous Topic Top Next Topic More |
To decide if your information is case- or event-related, check out the information here. |
In this part of the EventLog table, you will rename the event-related fields in the table event log (previously you have renamed the process analyzer information fields). As you can see in the code below, there are EventDimensionX fields which take dimensions describing the events context (like users, machines, ressources, ...).
1.Replace the EventDimensionX fields (as in the Helpdesk example) with the event names according to your data.
2.If you don't have enough data for all fields, i.e. no data for EventDimension3, just delete these fields. To avoid errors, the event dimensions used for filtering in the app are added to the MasterItemsImport table.
If you need more fields than the template provides, simply insert them as new EventDimension4 with the respective data field name.
//Event information
//Here you can add other event-related information (dimensions and values)
"UserName" as ActivityUserName,
if(WildMatch("UserName", '*batch*'), 0, 1) as RealUser,
if(WildMatch("ActivityName", '*Delete*','*Change*','*Cancel*','*Upgrade*','*Wait*'), 0, 1) as ReworkEvent,
EventDimension1,
EventDimension2,
EventDimension3
FROM [lib://Data/MPMData.qvd] (qvd)
where len(ActivityName) > 1;
Helpdesk example:
//Event information
//Here you can add other event-related information (dimensions and values)
User as ActivityUserName,
if(WildMatch("User", '*Batch*','*1*'), 0, 1) as RealUser,
if(Wildmatch(Activity,'*Delete*','*Change*','*Cancel*') > 0, 1, 0) as ReworkEvent,
EventResource, //EventDimension1
CumNetWorth //EventDimension2
FROM [lib://helpdesk/HelpdeskEventlog.qvd] (qvd)
where len(Activity) > 1;
It is very important, that the CaseInformation table holds exactly one row per case ID. |
In this table of the script tab 1C. Load EventLog, you will rename the case-related fields. We distinguish the event log from the CaseInformation in order to create a clearly understandable data model. The CaseInformation table basically behaves like the EventLog table. There are CaseDimensionX fields that can be replaced or must be deleted.
Never delete "CaseID" because this is the connection between the CaseInformation and EventLog tables. |
3.Replace the CaseDimensionX fields (as in the Helpdesk example) with your case names.
4.If you don't have enough data for all fields, e.g. no data for CaseDimension5, simply delete the respective row. To avoid errors, the case dimensions used for filtering in the app are added to the MasterItemsImport table.
If you need more fields than the template provides, simply insert them as new CaseDimension6 with the respective data field name.
For example, if you want to add a department, create a new row with a field named DepartmentName and name it as you like (e.g. "Department Name").
Left Keep(EventLog)
[CaseInformation_$(mvProcessDescription)]:
LOAD distinct
CaseID, // don't delete it
CaseDimension1,
CaseDimension2,
CaseDimension3,
CaseDimension4,
CaseDimension5,
Geofield // for example: city
FROM [$(DataConnection)/MPMData.qvd] (qvd);
Helpdesk example:
Left Keep(EventLog)
[CaseInformation_$(mvProcessDescription)]:
LOAD distinct
PurchaseOrderItem as CaseID,
Supplier,
Company,
SpendArea,
ProductClass,
ProcessPathUniqueNo,
City
FROM [lib://helpdesk/HelpdeskEventlog.qvd] (qvd);