cancel
Showing results for 
Search instead for 
Did you mean: 
OleksandrB
Sisense Team Member

How to create a list of users with a current role based on the usage analytics elasticube

Step-by-step guide: 

To get a list of the users with their roles, you can use table usage from the Usage analytics elasticube. We will need the next fields from it - email and userRole. Add these columns to your widget.

In this table, you can find all the roles that these users had previously:

 

OleksandrB_0-1743006539560.png

[ALT Text: A table displays two columns: email and userRole. User roles vary as Viewer, Data Designer, datadesigner, and Designer. Emails are redacted with red lines.]

To minimize the response to the last userRole, let's go to the Data - elasticube Usage Analytics, open the table usage table, and create a Custom Column.

 

OleksandrB_1-1743006715750.png

[ALT Text: Interface with a list of data fields on the left and a drop-down menu on the right. Arrows highlight "trackingId" and "Add Custom Column."]

 Name it - rank_date_ids
We will use the function RankCompetitionDesc (https://docs.sisense.com/main/SisenseLinux/mathematical-functions.htm)
Our query for this column will look like this:

RankCompetitionDesc( email, [timeStamp] )

Press the Save button and Build the Elasticube.

OleksandrB_2-1743006808053.png

[ALT Text: Screenshot showing a code editor with a function titled "RankCompetitionDesc" using parameters like email and timestamp. A blue "Save" button is highlighted.]

Go to the dashboard and edit our widget. Add a filter for a column rank_date_ids = 1

OleksandrB_3-1743006889264.png

[ALT Text:  "Screenshot of a filter menu in a usage analytics model interface. A drop-down list is open, displaying numbers 1 to 6. The number 1 is selected. Options to select all or clear all are visible. The interface displays 'Apply' and 'Cancel' buttons below."]

As a result, we will get the current user roles for every user.

 

OleksandrB_4-1743006958847.png

[ALT Text: A table with two columns, "email" and "userRole." Emails are redacted. Roles listed are "Viewer" and "Data Designer," alternating between rows.]

Disclaimer: This post outlines a potential custom workaround for a specific use case or provides instructions regarding a specific task. The solution may not work in all scenarios or Sisense versions, so we strongly recommend testing it in your environment before deployment. If you need further assistance with this, please let us know.

 

Rate this article:
Version history
Last update:
‎03-26-2025 09:40 AM
Updated by:
Contributors