public.vwlicensecountsbytype

public.vwlicensecountsbytype

Description

Aggregate license counts by license type

Table Definition
CREATE VIEW vwlicensecountsbytype AS (
 SELECT l.licensename,
    l.licensetype,
    count(DISTINCT l.userid) AS totalusers,
    sum(
        CASE
            WHEN (l.licenseactive = true) THEN 1
            ELSE 0
        END) AS activelicenses,
    sum(
        CASE
            WHEN (l.licenseactive = false) THEN 1
            ELSE 0
        END) AS inactivelicenses,
    sum(
        CASE
            WHEN (l.copilotlicense = true) THEN 1
            ELSE 0
        END) AS copilotlicenses,
    min(l.licenseassignmentdate) AS earliestassignment,
    max(l.licenseassignmentdate) AS latestassignment,
    max(l.updated) AS lastupdated
   FROM subuserlicensedata l
  WHERE (l.licensename IS NOT NULL)
  GROUP BY l.licensename, l.licensetype
)

Columns

Name Type Default Nullable Children Parents Comment
licensename varchar(100) true License Name
licensetype varchar(100) true
totalusers bigint true Total unique users with this license
activelicenses bigint true Count of active licenses
inactivelicenses bigint true
copilotlicenses bigint true Count of Copilot licenses
earliestassignment timestamp without time zone true
latestassignment timestamp without time zone true
lastupdated timestamp without time zone true

Referenced Tables

Name Columns Comment Type
public.subuserlicensedata 13 Per-user license assignments from Genesys Cloud. Tracks which licenses are assigned to each user including Copilot license status. BASE TABLE

    • Related Articles

    • public.evalquestiondata

      Description Columns Name Type Default Nullable Children Parents Comment keyid varchar(50) false evaluationid varchar(50) false evaluationformid varchar(50) false questiongroupid varchar(50) true questionid varchar(50) true answerid varchar(50) true ...
    • public.participantattributesdynamic

      Description Columns Name Type Default Nullable Children Parents Comment keyid varchar(50) false conversationid varchar(50) false conversationstartdate timestamp without time zone false conversationstartdateltc timestamp without time zone true ...
    • public.userpresencedetaileddata

      Description User Presence Detailed Data Columns Name Type Default Nullable Children Parents Comment keyid varchar(255) false Primary Key userid varchar(50) true Agent GUID starttime timestamp without time zone false Start Time (UTC) starttimeltc ...
    • public.userinteractionpresencedetaileddata

      Description Columns Name Type Default Nullable Children Parents Comment keyid varchar(255) false userid varchar(50) true starttime timestamp without time zone false starttimeltc timestamp without time zone true endtime timestamp without time zone ...
    • public.evaldata

      Description Columns Name Type Default Nullable Children Parents Comment keyid varchar(100) false conversationid varchar(50) false evaluationid varchar(50) false calibrationid varchar(50) true evaluationformid varchar(50) true evaluatorid varchar(50) ...