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

The FabCon + SQLCon recap series starts April 14th at 8am Pacific. If you’re tracking where AI is going inside Fabric, this first session is a can't miss. Register now

Reply
DemandMGR
Helper I
Helper I

Custom Column or Dax Formula

I am tying to write a Dax Formula or a Custom Column, preferrably a custom column.

 

I want the formula to reference two Date columns. The two columns are ETADATE and APPTDATE. My goal is to idenitfy all the ETADATEs that are Today+ 3 days that do not have a APPTDATE, which shows up in the APPTDATE column as 1/1/2001.

 

The Today+3days would have to be rolling over every day. I can also change the 1/1/2001 No APPT indicator to anything else so if that doesnt work I would be happy to replace that value with something else.

 

Please let me know if you need more information but I would greatly appreciate some assistance with this. Thank you for reading

1 ACCEPTED SOLUTION

@DemandMGR , Small correction on what @ryan has suggested. Please create a new custom column with below code:-

 

column  = IF (
    ETADATE = TODAY ()
        || ETADATE
            = TODAY () + 1
        || ETADATE
            = TODAY () + 2,
    "PO#",
    "NO"
)

 

Thanks,

Samarth

 

Best Regards,
Samarth

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin

View solution in original post

7 REPLIES 7
VahidDM
Super User
Super User

Hi @DemandMGR 

 

Can you post sample data as text and expected output?
Not enough information to go on;

please see this post regarding How to Get Your Question Answered Quickly:
https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

The most important parts are:
1. Sample data as text, use the table tool in the editing bar
2. Expected output from sample data
3. Explanation in words of how to get from 1. to 2.
4. Relation between your tables

Appreciate your Kudos!!
LinkedIn:www.linkedin.com/in/vahid-dm/

What I am looking for is something like an IF(OR) fucntion from excel. Please see example below.

 

IF(OR(ETADATE=TODAY(),ETADATE=TODAY()+1,ETADATE=TODAY()+2),"PO#","NO")

 

Honestly I think I can figure out the rest from there. I am not even sure if this is possible but I am hoping it is

 

@DemandMGR 

pls try this

IF(ETADATE=TODAY() || ETADATE=TODAY()+1 || ETADATE=TODAY()+2),"PO#","NO")





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

Proud to be a Super User!




Thank you for that. It didnt work though. There was an error under the E in the second ETADATE.

 

The examle of how I entered it below.

 

=IF([ETADATE]=TODAY() || [ETADATE]=TODAY()+1 || [ETADATE]=TODAY()+2),[PO#],'NO')

 

I have never seen an error under one letter when pulling in a column from the table. 

 

DemandMGR_0-1642713450199.png

 

@DemandMGR 

pls try to use DAX to create a colum, not in PQ.





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

Proud to be a Super User!




I also tried this formula but I kept getting a error trying to close the formula 

 

IF([ETADATE]=TODAY(),[PHPONO],IF([ETADATE]=TODAY()+1,[PHPONO],IF([ETADATE]=TODAY()+2,[PHPONO] ,'NO')

@DemandMGR , Small correction on what @ryan has suggested. Please create a new custom column with below code:-

 

column  = IF (
    ETADATE = TODAY ()
        || ETADATE
            = TODAY () + 1
        || ETADATE
            = TODAY () + 2,
    "PO#",
    "NO"
)

 

Thanks,

Samarth

 

Best Regards,
Samarth

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

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.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

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