How can I know the total number of users that worked/used on a Pega application within a month?
Is there an out of the box report that can do this or a query I can run directly into the DB?
Thanks,
-Byron
How can I know the total number of users that worked/used on a Pega application within a month?
Is there an out of the box report that can do this or a query I can run directly into the DB?
Thanks,
-Byron
@BYRONLOPEZ Please try with below
SELECT COUNT(*) AS “pySummaryCount(1)” FROM data.pr_operators “PC0” WHERE ( “PC0”.“pylastsignon” >= ? AND “PC0”.“pylastsignon” <= ? ) AND “PC0”.“pxobjclass” = ?
We can use the OOTB report “pyOperatorCount” to fetch the number of operators in access group. And we can add filter condition pyLastSignOn == Previous Month to get last 30days result.
On click of individual result the list of operator for that access group will be displayed.
It looks like the “pr_perf_stats” table saves all necessary information needed to tune a query and get this. In my case I was able to get a count of all operator sessions in a day with the following query. Date can be change a needed and remember this table only saves information for the last 30 days after that if automatically deleted unless this setting in changed.
SELECT COUNT() FROM (
SELECT
s.PYUSERIDENTIFIER ,
COUNT()
FROM schema_name.pr_perf_stats s
WHERE s.PXREQUESTORTYPE = ‘BROWSER’
AND s.PXREQUESTORSTART BETWEEN TO_TIMESTAMP(‘17-Jul-2022 1:00:00 AM’) AND TO_TIMESTAMP(‘17-Jul-2022 11:59:59 PM’)
GROUP BY s.PYUSERIDENTIFIER
);
Here you can find more info about this table.
https://docs-previous.pega.com/system-administration/87/system-wide-usage-and-log-usage-class
SELECT COUNT() FROM (SELECT s.PYUSERIDENTIFIER, COUNT() FROM pegaDATA.pr_perf_stats s WHERE s.PXREQUESTORTYPE = ‘BROWSER’ AND s.PXREQUESTORSTART < ‘31-Mar-2024 11:59:00 PM’ AND s.PXREQUESTORSTART > '01-Mar-2024 12:01:00 AM’GROUP BY s.PYUSERIDENTIFIER) AS name;
this query worked for me. But I could only get data of 2 months from this table.