Forum Discussion
aadass
8 years agoFrequent Visitor
Problem to use DATEDIFF function between two dates which located in two not directly related tables
Problem to use DATEDIFF function between two dates which located in two but not directly related tables. Task: Stock.Registration_Date - Invoices.InvoiceDate Formula: NeedDate= DATEDIFF([R...
- 8 years ago
Given the relationship, you may use RELATEDTABLE Function.
MAXX ( RELATEDTABLE ( Invoices ), Invoices[InvoiceDate] )
v-chuncz-msft
8 years agoCommunity Support
Given the relationship, you may use RELATEDTABLE Function.
MAXX ( RELATEDTABLE ( Invoices ), Invoices[InvoiceDate] )
aadass
8 years agoFrequent Visitor
Sam,
i think it solved my issue:
Weeks in stock = DATEDIFF([Registration_Date],MAXX(RELATEDTABLE(Invoices),Invoices[InvoiceDate]),WEEK)
I would never thought that MAXX can act as a little liason between "unrelated" tables
Thank you much
Angelika