LoginFrequency__c
Sobject
global class LoginFrequency__c extends SObjectExtends: SObject
Tracks monthly login activity per user, including total login count and number of unique days logged in. Used for login adoption reporting.
Fields
| Field | Description |
|---|---|
| global String CompositeKey__c | Composite unique key combining User ID, year, and month to ensure one record per user per month. |
| global Decimal LoginMonth__c | The calendar month (1-12) for this login frequency record. |
| global Decimal LoginYear__c | The calendar year for this login frequency record. |
| global Date ReportingDate__c | Formula-generated date set to the first day of the login month/year, enabling relative date filtering in reports (e.g. |
| global Decimal TotalLoginCount__c | Total number of login events for this user in the given month. |
| global Decimal UniqueLoginCount__c | Number of distinct days the user logged in during the given month. |
| global Id User__c | The user whose login activity is tracked by this record. |
| global User User__r | The user whose login activity is tracked by this record. |
Field Details
CompositeKey__c
global String CompositeKey__cComposite unique key combining User ID, year, and month to ensure one record per user per month.
Field Attributes:
| Attribute | Value |
|---|---|
| Data Type | Text(40), case-insensitive |
| Required | false |
| Unique | true |
| External ID | true |
LoginMonth__c
global Decimal LoginMonth__cThe calendar month (1-12) for this login frequency record.
Field Attributes:
| Attribute | Value |
|---|---|
| Data Type | Number(4,0) |
| Required | false |
| Unique | false |
| External ID | false |
LoginYear__c
global Decimal LoginYear__cThe calendar year for this login frequency record.
Field Attributes:
| Attribute | Value |
|---|---|
| Data Type | Number(4,0) |
| Required | false |
| Unique | false |
| External ID | false |
ReportingDate__c
global Date ReportingDate__cFormula-generated date set to the first day of the login month/year, enabling relative date filtering in reports (e.g. THIS_YEAR, LAST_N_MONTHS).
Field Attributes:
| Attribute | Value |
|---|---|
| Data Type | Date |
| Required | false |
| Formula | DATEVALUE(TEXT(LoginYear__c) & '-' & TEXT(LoginMonth__c) & '-' & '01') |
TotalLoginCount__c
global Decimal TotalLoginCount__cTotal number of login events for this user in the given month. Includes all login types (UI, API, etc.).
Field Attributes:
| Attribute | Value |
|---|---|
| Data Type | Number(10,0) |
| Required | false |
| Unique | false |
| External ID | false |
UniqueLoginCount__c
global Decimal UniqueLoginCount__cNumber of distinct days the user logged in during the given month. A user who logs in 5 times on the same day counts as 1 unique day.
Field Attributes:
| Attribute | Value |
|---|---|
| Data Type | Number(4,0) |
| Required | false |
| Unique | false |
| External ID | false |
User__c
global Id User__cThe user whose login activity is tracked by this record.
Field Attributes:
| Attribute | Value |
|---|---|
| Data Type | User |
| Required | false |
User__r
global User User__rThe user whose login activity is tracked by this record.
Field Attributes:
| Attribute | Value |
|---|---|
| Data Type | User |
| Required | false |