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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
Anonymous
Not applicable

need to display a message based on strtdate and enddate

Hi Team,

need to display a message based on strtdate and enddate for 30 days from current date,if enddate is greterthan today need to show on cloumn(shot desc) otherwise need to display "No Maintenance" and if table is blank also need to display "No Maintenance".

 

strtdate           enddate          shortdesc

01/06/2020   10/06/200        bw maintenance

above case we need to display "bw mantenace"

 

strtdate           enddate          shortdesc

01/06/2020   5/06/200        bw maintenance

above case we need to display "No mantenace"

 

strtdate           enddate          shortdesc

need to display "No mantenace"

 

Regards,

Ravi

 

 

 

 

1 ACCEPTED SOLUTION
v-alq-msft
Community Support
Community Support

Hi, @Anonymous 

 

Based on your description, you may create a measure as below.

 

 

Desc1 = 
IF(
    COUNTROWS(Table1)>0,
    IF(
        SELECTEDVALUE(Table1[enddate])>=TODAY()+30,
        "bw mantenace",
        "No mantenace"
    ),
    "No mantenace"
)

 

 

Result:

b1.png

 

 

Best Regards

Allan

 

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

4 REPLIES 4
v-alq-msft
Community Support
Community Support

Hi, @Anonymous 

 

If you take the answer of someone, please mark it as the solution to help the other members who have same problems find it more quickly. If not, let me know and I'll try to help you further. Thanks.

 

Best Regards

Allan

v-alq-msft
Community Support
Community Support

Hi, @Anonymous 

 

Based on your description, you may create a measure as below.

 

 

Desc1 = 
IF(
    COUNTROWS(Table1)>0,
    IF(
        SELECTEDVALUE(Table1[enddate])>=TODAY()+30,
        "bw mantenace",
        "No mantenace"
    ),
    "No mantenace"
)

 

 

Result:

b1.png

 

 

Best Regards

Allan

 

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

 

 

amitchandak
Super User
Super User

@Anonymous , try a new column like

new column = if([start Date]<= today()+30 && [end Date]<= today()+30 && [End Date]> Today(),"bw maintenance","No mantenace")

 

Do any changes you need

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

Thanks for the response.

if table is blank need to display no maintenance but you logic aslo giving blank .

 if we have two entries in table one is outdated and one is with in thirty days with your logic we are getting two values one is no maintenance and another bw maintenance ,Need to display only current one .

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.