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

Data Days is here! Join us now for 60+ days of learning, challenges, and connection. Learn more

Reply
SUMESHKUMAR22
Helper IV
Helper IV

Create custom text based date on X axis

Hi BI folks,

 

Im looking our for a ideal / best approaches to handle below type of visual requirement in purely Power BI or SQL code. How to build the data view for this?

IMG_0458.jpeg

In the mockup image, its Showing last 2-weeks dynamic (2 bars) and the base case (black bar) is constant value.

For a KPI, Basically showing dynamic last 2 weeks with a black constant bar & the circle dot changing as per the last week value more than base case -(black bar) .

 

Please any reference/workaround would be appreciated.

 

Thanks!

1 ACCEPTED SOLUTION

@SUMESHKUMAR22 

since we don't have the fact table, i can only create the date table for testing.

 

pls see the attachment below





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

4 REPLIES 4
ryan_mayu
Super User
Super User

do you have a date slicer that will change the date or if the data were updated, this visual always display last 2 weeks data?

what's more, could you pls provide some sample data? how we get the base case value?





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




hi Ryan,


- Always display last 2 weeks (sun-sat) dynamically (looking into it today- it will be 30 mar - 5 mar (Previous week)& 6 - 12 mar (last week)). Current week will not be included because its has not completed the full 7 days timeframe.

 

- for base case, we can enter sample data using datatable in power bi (kpi name & base value) as its a constant value.

 

thanks in advance!

 

@SUMESHKUMAR22 

since we don't have the fact table, i can only create the date table for testing.

 

pls see the attachment below





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




SUMESHKUMAR22
Helper IV
Helper IV

Hi Team,

 

Currently my fact model looks like below:

date, kpi name, few dimensions, Units (sum/divide), value , value 1.

my generic calculation: if the Units = 'sum' then sum(value) else sum(value)/ sum(value1)


Also for the above case of scenario should I create a disconnected table approach?


Help me with the steps please. Thanks!

 

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

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

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.