Forum Discussion

TIGER8855's avatar
TIGER8855
Helper I
3 years ago
Solved

Extract dates from separate tables

I need to create a new column in my data showing the due date for items however some of my items have a due date where the value of the due date is in a seperate table. In the original table there is no date and instead an identifier is shown and the other table shows the value (Date) of that identifier.

 

Below is a sample of the data. Can anyone advise on the formula required to create a new column in Table A with all the due dates?

 

Table A

ItemSerial NumberInstance
1A-00418/10/2024
2A-00625/02/2026
3A-001A
4A-002A
5A-001B
6A-001A
7A-002B
8A-002A
9A-002B

 

Table B

Serial NumberInstanceDate
A-001A31/01/2024
A-001B31/01/2025
A-001C31/01/2026
A-002A15/06/2024
A-002B20/08/2025
A-002C

31/01/2026

 

  • Hi,

    Write this calculated column formula in Table1

    Column = CALCULATE(MAX(Table2[Date]),FILTER(Table2,Table2[Serial Number]=EARLIER(Table1[Serial Number])&&Table2[Instance]=EARLIER(Table1[Instance])))

    Hope this helps.

3 Replies

  • Hi,

    Write this calculated column formula in Table1

    Column = CALCULATE(MAX(Table2[Date]),FILTER(Table2,Table2[Serial Number]=EARLIER(Table1[Serial Number])&&Table2[Instance]=EARLIER(Table1[Instance])))

    Hope this helps.