Brian Dunning's FileMaker Custom Functions

RangesOverlap ( start1 ; end1 ; start2 ; end2 )

Check if two ranges of dates or numbers overlap (inclusive)

  Average rating: 5.0 (1 vote) Log in to vote

Joshua Willing   Joshua Willing
Willing Apps

Share on Facebook Share on Twitter

  Sample input:
RangesOverlap ( 1 ; 10 ; 5 ; 15 )
  Sample output:
1

  Function definition: (Copy & paste into FileMaker's Edit Custom Function window)

This will return 1 or 0 depending on if the two ranges overlap. The inputs can be numbers or dates, but because the function uses GetAsNumber, be sure to input an actual date data type if using dates. Date strings like "11/23/2018" will be converted to 11232018, which will return unexpected results if you intended to compare dates.

 

Comments

Log in to post comments.

 

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

Under construction. Email me your wish list for improvements.