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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Need help in DAX

Hi experts,

 

I have a problems that need your help.

I got 3 table:

1. Fact Table: Login Event

2. Dim Table: Total users

3. Dim Table: Date

The relationship will look like below picture

2.PNG

 

In 1 report page:

- Filter: Date (from Date table)

- Chart 1: List of user had login in the given date filter

- Now I need to build, with the same given date filter, the list of NOT- LOGIN USER.

 

Please give me some advises.

 

Thanks in advance!!

1 ACCEPTED SOLUTION

@Anonymous 

 

You can find not login users with NOT in Values() function:

Not login users = CALCULATE(MAX('DIM total users'[user]), FILTER('DIM total users', NOT('DIM total users'[user]) in VALUES( Fact_Login event[user])))


Paul Zheng _ Community Support Team
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
  

View solution in original post

3 REPLIES 3
PaulDBrown
Community Champion
Community Champion

@Anonymous 

Try:

not logged in =

VAR users = VALUES(DIM total users[user])

VAR logged = VALUES(Fact_Login event[user])

RETURN

COUNTROWS(EXCEPT(users,logged))

 

Create the visual/table/chart with the DIM total user[user] field, and in the filters for the visual in the filter pane add this measure [not logged in ] and establish the filter value as 1





Did I answer your question? Mark my post as a solution!
In doing so, you are also helping me. Thank you!

Proud to be a Super User!
Paul on Linkedin.






@Anonymous 

 

You can find not login users with NOT in Values() function:

Not login users = CALCULATE(MAX('DIM total users'[user]), FILTER('DIM total users', NOT('DIM total users'[user]) in VALUES( Fact_Login event[user])))


Paul Zheng _ Community Support Team
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
  

amitchandak
Super User
Super User

@Anonymous , Make the join between Date and use as inactive and User dim Login Fact as active.

 

When you need some data from use dime with date cross filter with fact login and use relation with.

 

refer

https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-trend/ba-p/882970

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.