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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
Jeffrey_VC
Helper III
Helper III

Dax function datesbetween

Hi,

 

I'm trying to build a measure to calculate records.
In this measure I'm using the function Datesbetween.
It looks that that function working but when I add a slicer to this data the data will be the same.

What I'm doing wrong?

 

Records user = CALCULATE(

    COUNTROWS('Query1'),

    DATESBETWEEN(Datetable[date], MIN(vc_lot_lotuser[Start Date]), MAX(vc_lot_lotuser[End Date])),

    USERELATIONSHIP(vc_lotuser[Lot User], Query1[LotId]))

 
Thnx!
7 REPLIES 7
FreemanZ
Super User
Super User

hi @Jeffrey_VC 

which column do you have for the slicer?

If it is date-relevant column, ensure to take the columns from the datetable.

Hi @FreemanZ 

I'm using de Datetable[date] in my slicer.

 

hi @Jeffrey_VC 

how are the three tables related?

This is the model:

 

Jeffrey_VC_0-1675344486193.png

 

@FreemanZ 

this is the model:

Jeffrey_VC_0-1675851925648.png

 

 

hi @Jeffrey_VC 

 

what column do you have for the mentioned slicer?

Hi @FreemanZ ,

 

I'm using the column "date" from the table datetable

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.