Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I had two tables originally - one with all "Notifications" created and a table of all employee user names. I created a mapping table to determine which Notifications were created by the employees in my list.
AllNotifications:
LOAD
Notification,
Notif.date,
"Notifictn type",
Description,
"Created on",
"System status",
"User status",
"Functional Loc.",
Equipment,
"Changed on",
"Created by" as [User Name],
"Changed by",
Coding,
"Completn date",
"Operations Centre",
Township,
"Req. start",
"Order",
"Main WorkCtr"
EmployeeNotifications:
LOAD
"User Name",
"Employee Name",
"Building Code"
FROM [lib://1C Metrics/Employee ID Ops Centre.xlsx]
(ooxml, embedded labels, table is [Employee ID and Ops Centre]);
MapEmployeeNotifications:
MAPPING LOAD
[User Name],
'Yes'
RESIDENT EmployeeNotifications;
New_Table:
LOAD
[User Name],
ApplyMap('MapEmployeeNotifications',[User Name],'No') AS RaisedByField
RESIDENT AllNotifications;
I want to create a pie chart that counts the number of each type of Notification (Notifictn type) but ONLY for those Notifications that were created by the employees in my list (RaisedByField).
I've created a pie chart now:
Dimension=[Notifictn type]
Measure=count([Notifictn type])
But this includes all of the notifications from the first table, and not only the ones that were RaisedByField
I am able to get the result I want by adding a filter pane for "RaisedByField" and only selecting "Yes", but can I embed this into the pie chart somehow?
Try this Set analysis in your expression;
count({<RaisedByField={'Yes'}>}[Notifictn type])
Try this Set analysis in your expression;
count({<RaisedByField={'Yes'}>}[Notifictn type])