Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi all,
I have date in a hierchy bar chart.
In my Date Table, I've created an extra month after my data ends. I am using this month as my "Forecasting Month". I attached a measure to this blank date.
However, I can't seem to rename this date to "Forecasting", when I plug it into my table. I am aware this can be done with indexing, but I'd like to keep it in date hierchy form, not text (to drill down). How can I change the name of the final month-date on the bar chart?
Solved! Go to Solution.
Hi @acamar22 ,
Regarding your question, I guess you are using the date hierarchy that Power BI automatically creates.
We can manually create a date hierarchy for drilling.
The Table data is shown below:
Please follow these steps:
1.Use the following DAX expression to create a table
Table 2 =
VAR _table = UNION('Table',ROW("Date",BLANK(),"Value",BLANK()))
RETURN ADDCOLUMNS(_table,
"Year",IF(ISBLANK([Date]),"Forecasting",YEAR([Date]) & ""),
"Quarter",IF(ISBLANK([Date]),"Forecasting",QUARTER([Date]) & ""),
"Month",IF(ISBLANK([Date]),"Forecasting",MONTH([Date]) & ""),
"Day",IF(ISBLANK([Date]),"Forecasting",DAY([Date]) & "")
)
2.Final output
Best Regards,
Wenbin Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @acamar22 ,
Regarding your question, I guess you are using the date hierarchy that Power BI automatically creates.
We can manually create a date hierarchy for drilling.
The Table data is shown below:
Please follow these steps:
1.Use the following DAX expression to create a table
Table 2 =
VAR _table = UNION('Table',ROW("Date",BLANK(),"Value",BLANK()))
RETURN ADDCOLUMNS(_table,
"Year",IF(ISBLANK([Date]),"Forecasting",YEAR([Date]) & ""),
"Quarter",IF(ISBLANK([Date]),"Forecasting",QUARTER([Date]) & ""),
"Month",IF(ISBLANK([Date]),"Forecasting",MONTH([Date]) & ""),
"Day",IF(ISBLANK([Date]),"Forecasting",DAY([Date]) & "")
)
2.Final output
Best Regards,
Wenbin Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
16 | |
15 | |
14 | |
12 | |
11 |
User | Count |
---|---|
19 | |
15 | |
14 | |
11 | |
9 |