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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
peterh
Regular Visitor

FIRSTDATE() Issue

I have created measures using FIRSTDATE() and LASTDATE() and named them Selected Start Date and Selected End Date, respectively. I have added these values as filters to other measures. For filtering, I have added month and year slicers to filter a calendar table.

 

As an example, I have selected May 2016 in the slicers. When I add the Selected Start Date value to the page, the value shows up as 5/1/2016. When I look at measures using the Selected Start Date value, it uses 1/1/1900 as the date. Why would the value be correct on the page but incorrect in the measures using the Selected Start Date value? The Selected End Date shows up correctly in the other measures.

1 REPLY 1
v-micsh-msft
Microsoft Employee
Microsoft Employee

Hi peterh,

 

Would you please share the measure you used here? As the date 1/1/1900 ( I should say, this is a leap year, but the date function sometimes not agree with that) returned, you might hit some interesting things when using date and time functions. : ) 

FIRSTDATE () (LASTDATE () ) function would return the first date (last date) in the current context for the specified column of dates. The current context means the context which the measure calculated in.

Regarding the situation you mentioned, I suggest we check the following two parts first:

1. Check the Visual Interaction setting (Power BI desktop, when selecting Visuals, choose format tab ->Edit Interactions) between the slicer and the measure using FIRSTDATE () function;

2. Verify the measure itself, see if there are any calculated filters in this measure which would remove the Slicer filter, such as all function.

Regards

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

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.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.