Help

I'm brutal with formulae

Topic Labels: Formulas
170 1
cancel
Showing results for 
Search instead for 
Did you mean: 
Siobhan_Mc_Kenn
4 - Data Explorer
4 - Data Explorer

Hi all,

 

I'm pretty useless with formulae generally and just wondering if anyone can help with this.

I'm trying to generate a formula field that is based on a source date. The formula is to calculate 8 months + 23 days from the source date (i.e the 23rd day of the 9th month after my source date).

I also want to include an "If" being; If field A is populated, then field C should be the 23rd day of the 9th month after field B. Does this make sense?

Below is what I have but depending on whether the source field has 28, 30 or 31 days, I am getting variable dates.

IF({Next Accounts Reqd},DATEADD(DATEADD({Next Accounts Reqd},8,'month'),23,'day'))
1 Reply 1

Hm not sure I understood, let me know where I've got it wrong and I'll see what I can do!

Screenshot 2024-03-24 at 2.37.31 PM.png

IF(
  {Field A},
  DATEADD(
    DATEADD(
      DATETIME_PARSE(
        DATETIME_FORMAT(
          {Next Accounts Reqd},
          "MM YYYY"
        ),
        "MM YYYY"
      ),
      8,
      'months'
    ),
    22,
    'days'
  )
)