Forum Discussion

pgd's avatar
pgd
Frequent Visitor
3 years ago

Match Single Date to Date Range

I am performing merges in Power Query based on 3 concatenated fields. The fields are hotel, room number, and date. I am merging two tables - 1 and 2. Table 1 has the date as a single date. Table 2 has a date range with a check in date in one column and the check out date in another column. How do I match a date (from table 1) to a date range (from table 2)? For example, in Table 1, I have Marriott 303 1/6. In Table 2, I have Marriott 303 1/1 - 1/10. This should be a match since 1/6 is within 1/1 - 1/10, but this won't be a match in Power Query since Marriott 303 1/6 does not equal Marriott 303 1/1 - 1/10.