cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
haan1207 Frequent Visitor
Frequent Visitor

Need help with displaying month - year instead of year on X-axis (problem not solved)

Hi guys,

 

I want to display month and year like the red graph (excel) below with the data visualize by each date like the blue graph ( power bi). The power bi is fixed with the year and cant be changed. 
I already read some solution post which were suggested to "group by" month by using the date hieracchy but I dont accept this solution. 

xoa_1.pngxoa_2.png

Please give me advice! 

Note: I need the data visualized by date not by suming up each month. 

6 REPLIES 6
venal Senior Member
Senior Member

Re: Need help with displaying month - year instead of year on X-axis (problem not solved)

@haan1207 

Please try to create a two columns.

 

Mnth = MONTH(EMP[HIREDATE])
MnthYr = SWITCH(EMP[Mnth],1,"Jan",2,"Feb",3,"Mar",4,"Apr",5,"May",6,"Jun",7,"Jul",8,"Aug",9,"Sep",10,"Oct",11,"Nov",12,"Dec")&"-"&YEAR(EMP[HIREDATE])
 
 
Instead of above two columns, create a only one column like below.
 
Column = SWITCH(MONTH(EMP[HIREDATE]),1,"Jan",2,"Feb",3,"Mar",4,"Apr",5,"May",6,"Jun",7,"Jul",8,"Aug",9,"Sep",10,"Oct",11,"Nov",12,"Dec")&"-"&YEAR(EMP[HIREDATE])
Now use the "MnthYr" column in the bar chart.
 

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

If this post was helpful may I ask you to mark it as solution and give it some kudos?

haan1207 Frequent Visitor
Frequent Visitor

Re: Need help with displaying month - year instead of year on X-axis (problem not solved)

@venal 

this will cause to a "group by" month which is not my demand, what I want is to visualise the month_year on the axis not group by a data into month.

 

Thanks anyways,

An. 
Confirmation : this is not a solution for my post.

Community Support Team
Community Support Team

Re: Need help with displaying month - year instead of year on X-axis (problem not solved)

Hi @haan1207 ,

 

>>Note: I need the data visualized by date not by summing up each month. 

 

Generally, if you put the Month-Year onto the axis, the data will be summarized by the month. If you need the data visualized by date, you may put the date field onto the axis box of visual. Maybe you need the date in hierarchy form and display the month and year on axis, right?

 

I am not sure what desired result would you want, could you please share your sample data and desired output screenshots for further analysis?

 

Best Regards,

Amy

 

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

haan1207 Frequent Visitor
Frequent Visitor

Re: Need help with displaying month - year instead of year on X-axis (problem not solved)

@v-xicai  as you can see the blue chart which is visualised by power bi and date data but the x-axis is visualized by Year only. (though it must be the very each date). So instead of year, I want it to be replaced by year month. 

Community Support Team
Community Support Team

Re: Need help with displaying month - year instead of year on X-axis (problem not solved)

Hi @haan1207 ,

 

So you may display the Year and Month in the Fields pane when put the date filed into the visual, and click

79.png

Best Regards,

Amy

 

Community Support Team _ Amy

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

 

haan1207 Frequent Visitor
Frequent Visitor

Re: Need help with displaying month - year instead of year on X-axis (problem not solved)

@v-xicai : Yes the X-Axis will be named year month but the data is not  visualised day by day as in my post. 
The out come I want is showing exactly the graph in my 1st post  but the axis show year month ( not year as it automatically set)

- not the single bar chart by each month.

 

thanks!

Helpful resources

Announcements
New Kudos Received Badges Coming

New Kudos Received Badges Coming

Kudos to you if you earned one of these! Check your inbox for a notification.

Microsoft Implementation for Communities Wins Award

Microsoft Implementation for Communities Wins Award

Learn about the award-winning innovation that was implemented across Microsoft’s Business Applications Communities.

Power Platform World Tour

Power Platform World Tour

Find out where you can attend!

Top Kudoed Authors (Last 30 Days)
Users online (4,920)