Skip to main content
cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Bu__
Frequent Visitor

identifying active users every month

Hi,

I have a list of users every month, and i need to find the active users in every month. maybe by creating a new calculated column which states if the user is active or not

- If the user names present in the next available month file then those user names are active 

or

- if a new user appears for the very first time which are not available in any of the month files then they are active from that month onwards.

Please note if user names not appearing continuously then they are inactive.

 

please find the data like below:

column names are:

System user name,Count of System user name,Sum of cost,Monthly Source file Name

System user nameCount of System user nameSum of costMonthly Source file Name
User_A3โ‚ฌ 112.5024-Jan
User_A3โ‚ฌ 112.5024-Mar
User_A3โ‚ฌ 112.5024-Apr
User_A3โ‚ฌ 112.5024-May
User_A3โ‚ฌ 112.5024-Jun
User_A3โ‚ฌ 112.5024-Sep
User_B7โ‚ฌ 149.5024-Mar
User_B7โ‚ฌ 149.5024-Apr
User_B7โ‚ฌ 149.5024-May
User_B7โ‚ฌ 149.5024-Jun
User_B8โ‚ฌ 238.5024-Sep
User_C5โ‚ฌ 139.5024-Jan
User_C7โ‚ฌ 151.5024-Mar
User_C7โ‚ฌ 151.5024-Apr
User_C7โ‚ฌ 151.5024-May
User_C7โ‚ฌ 151.5024-Jun
User_C7โ‚ฌ 151.5024-Sep
User_D12โ‚ฌ 323.0024-Jan
User_D13โ‚ฌ 329.0024-Mar
User_D13โ‚ฌ 329.0024-Apr
User_D13โ‚ฌ 329.0024-May
User_D13โ‚ฌ 329.0024-Jun
User_D14โ‚ฌ 332.0024-Sep
User_E5โ‚ฌ 138.5024-Jan
User_E7โ‚ฌ 209.5024-Mar
User_E7โ‚ฌ 209.5024-Apr
User_E9โ‚ฌ 222.5024-May
User_E9โ‚ฌ 222.5024-Jun
User_E9โ‚ฌ 305.0024-Sep
User_F11โ‚ฌ 362.5024-Jan
User_F13โ‚ฌ 374.5024-Mar
User_F14โ‚ฌ 380.5024-Apr
User_F14โ‚ฌ 380.5024-May
User_F14โ‚ฌ 380.5024-Jun
User_F14โ‚ฌ 463.5024-Sep
User_G6โ‚ฌ 219.5024-Apr
User_G7โ‚ฌ 226.0024-May
User_G6โ‚ฌ 219.5024-Jun
User_G7โ‚ฌ 246.5024-Sep
User_H3โ‚ฌ 112.5024-Mar
User_H3โ‚ฌ 112.5024-Apr
User_H3โ‚ฌ 112.5024-May
User_H3โ‚ฌ 112.5024-Jun
User_H3โ‚ฌ 112.5024-Sep

Bu___0-1732527320344.png

How do i create  this Active users list every month using the above data in power bi??

Thanks in advance for the help

1 ACCEPTED SOLUTION
Kedar_Pande
Super User
Super User

@Bu__ 

Create a Calculated Column

User Status = 
VAR CurrentUser = 'YourTable'[System user name]
VAR CurrentMonth = 'YourTable'[Monthly Source file Name]
VAR NextMonth =
CALCULATE(
MIN('YourTable'[Monthly Source file Name]),
FILTER(
'YourTable',
'YourTable'[System user name] = CurrentUser && 'YourTable'[Monthly Source file Name] > CurrentMonth
)
)
VAR PreviousMonths =
CALCULATE(
COUNTROWS('YourTable'),
FILTER(
'YourTable',
'YourTable'[System user name] = CurrentUser && 'YourTable'[Monthly Source file Name] < CurrentMonth
)
)
VAR IsFirstTime = PreviousMonths = 0

RETURN
IF (
IsFirstTime,
"Active",
IF (
NOT ISBLANK(NextMonth),
"Active",
"Inactive"
)
)

๐Ÿ’Œ If this helped, a Kudos ๐Ÿ‘ or Solution mark would be great! ๐ŸŽ‰
Cheers,
Kedar
Connect on LinkedIn

View solution in original post

2 REPLIES 2
bhanu_gautam
Super User
Super User

@Bu__ , 

Create a Calculated Column for Active Status:

Go to the "Modeling" tab and select "New Column".
Use the following DAX formula to create a calculated column that checks if a user is active in the next month:

Active Status =
VAR CurrentMonth = 'Table'[Monthly Source file Name]
VAR CurrentUser = 'Table'[System user name]
VAR NextMonth = CALCULATE(MIN('Table'[Monthly Source file Name]), 'Table'[Monthly Source file Name] > CurrentMonth)
RETURN
IF(
ISBLANK(NextMonth),
"Inactive",
IF(
COUNTROWS(
FILTER(
'Table',
'Table'[System user name] = CurrentUser &&
'Table'[Monthly Source file Name] = NextMonth
)
) > 0,
"Active",
"Inactive"
)
)

 

 

Then  Use the following DAX formula to determine if a user appears for the first time:
First Appearance =
VAR CurrentUser = 'Table'[System user name]
VAR FirstMonth = CALCULATE(MIN('Table'[Monthly Source file Name]), 'Table'[System user name] = CurrentUser)
RETURN
IF(
'Table'[Monthly Source file Name] = FirstMonth,
"Active",
BLANK()
)

 

Then Combine the Active Status and First Appearance:
Create another calculated column to combine the results of the previous two columns:
Final Active Status =
IF(
'Table'[First Appearance] = "Active",
"Active",
'Table'[Active Status]
)


Create a Visual to Display Active Users:
Use a table or matrix visual to display the System user name, Monthly Source file Name, and Final Active Status.
You can also use filters to show only active users for each month.




Did I answer your question? Mark my post as a solution! And Kudos are appreciated

Proud to be a Super User!




LinkedIn






Kedar_Pande
Super User
Super User

@Bu__ 

Create a Calculated Column

User Status = 
VAR CurrentUser = 'YourTable'[System user name]
VAR CurrentMonth = 'YourTable'[Monthly Source file Name]
VAR NextMonth =
CALCULATE(
MIN('YourTable'[Monthly Source file Name]),
FILTER(
'YourTable',
'YourTable'[System user name] = CurrentUser && 'YourTable'[Monthly Source file Name] > CurrentMonth
)
)
VAR PreviousMonths =
CALCULATE(
COUNTROWS('YourTable'),
FILTER(
'YourTable',
'YourTable'[System user name] = CurrentUser && 'YourTable'[Monthly Source file Name] < CurrentMonth
)
)
VAR IsFirstTime = PreviousMonths = 0

RETURN
IF (
IsFirstTime,
"Active",
IF (
NOT ISBLANK(NextMonth),
"Active",
"Inactive"
)
)

๐Ÿ’Œ If this helped, a Kudos ๐Ÿ‘ or Solution mark would be great! ๐ŸŽ‰
Cheers,
Kedar
Connect on LinkedIn

Helpful resources

Announcements
November Fabric Update Carousel

Fabric Monthly Update - November 2025

Check out the November 2025 Fabric update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Users online (25)