Compare Start Date value with End date list

Hello folks.

Iโ€™d like some assistance with writing an expression i feel dumb asking about.

Long story short, I got a โ€œVacationโ€ table, for when people are on PTO vacation.

It has 2 columns,
โ€œStart Dateโ€ ( the date the person begins vacation)
โ€œEnd Dateโ€ ( the date the person ends vacation)

Simply put, I donโ€™t want people to make a new entry if the Start Date is before an End Date already in the table. (They shouldnโ€™t make a new vacation record if itโ€™s within the time span of a previous one)

So I need a ValidIf formula that says โ€œthis rowโ€™s Start Date is greater than all this tableโ€™s End Datesโ€

I wrote the following formula,

[_THISROW].[Start Date] > [End Date]

but it always returns false, even when the new Start Date is greater than all End Dates.

I canโ€™t figure out the problem solution. Does anyone have any insight?

Solved Solved
0 2 973
1 ACCEPTED SOLUTION

Steve
Platinum 4
Platinum 4

Your expression:

[_THISROW].[Start Date] > [End Date]

Compares the Start Date column value of the row with the End Date column value of the same row.

Given this:

It seems like you want:

([Start Date] > MAX(Vacation[End Date]))

See also:



View solution in original post

2 REPLIES 2

Steve
Platinum 4
Platinum 4

Your expression:

[_THISROW].[Start Date] > [End Date]

Compares the Start Date column value of the row with the End Date column value of the same row.

Given this:

It seems like you want:

([Start Date] > MAX(Vacation[End Date]))

See also:



Yes! that was i was looking for. Agh, I knew it was a dumb question. Many thanks for the swift response, Steve!

Top Labels in this Space