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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Syndicate_Admin
Administrator
Administrator

Grouping data by dates

Good!

I have created a line graph in which on the horizontal axis you have the time and on the vertical axis a measurement.

I want to create a filter that is similar to the one in the following image:

Luisch_0-1724839923979.png

In which, the option to group by date if I select "By months" shows me the data grouped by months, if I select "By days" I do it by days and if I select by years I do it by years. That is, the horizontal axis of my graph varies automatically according to the selection I make in the second filter.

Thank you!

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Syndicate_Admin ,
According to your description, you can create a column corresponding to the year, month, and day based on your date, and then use the year, month, and day columns to create a filed parameter and put this parameter into the x-axis of the line graph, as follows
Create day, month,year column

DAY = DAY('Table'[Date])
MONTH = MONTH('Table'[Date])
YEAR = YEAR('Table'[Date])

Use these columns as filed parameter value

vheqmsft_0-1724914735589.png

vheqmsft_1-1724914749227.png

Use parameter as x-axis

vheqmsft_2-1724914772001.png

Final output

vheqmsft_3-1724914801540.png

vheqmsft_4-1724914814402.png

 

Best regards,
Albert He


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

2 REPLIES 2
Anonymous
Not applicable

Hi @Syndicate_Admin ,
According to your description, you can create a column corresponding to the year, month, and day based on your date, and then use the year, month, and day columns to create a filed parameter and put this parameter into the x-axis of the line graph, as follows
Create day, month,year column

DAY = DAY('Table'[Date])
MONTH = MONTH('Table'[Date])
YEAR = YEAR('Table'[Date])

Use these columns as filed parameter value

vheqmsft_0-1724914735589.png

vheqmsft_1-1724914749227.png

Use parameter as x-axis

vheqmsft_2-1724914772001.png

Final output

vheqmsft_3-1724914801540.png

vheqmsft_4-1724914814402.png

 

Best regards,
Albert He


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

 

 

 

 

Anonymous
Not applicable

@Syndicate_Admin can u help me pls. I posted something about expanding tables and my questions is not good formulated. Can you look over it?

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI 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.

Top Solution Authors
Top Kudoed Authors