Forum Discussion

sdlx's avatar
sdlx
Helper I
4 years ago
Solved

Add a Colum with a value based on a conditional test between value of 2 different Table

Hello,

 

I have 2 table.

First Table

Batch Start Value Batch (Decimal Number) End Value Batch (Decimal Number)

 

Second Table

Start Value Reason (Decimal Number) 

 

My Goal is to add the Batch Value From the first Table to the second table.

The batch Value to retrieve is the one where the Start Value Reason is between Start Value Batch and End Value Batch.

multiple rows of the Second Table will Get the same Batch Value of the First Batch.

 

Thank you all for your help !

 

 

  • sdlx , Try a column like

    maxx(filter(table1, Table2[Start Value Reason] >= Table1[Start Value Batch]  && Table2[Start Value Reason] <= Table1[End Value Batch] ), Tabl1[Batch])

2 Replies

  • sdlx , Try a column like

    maxx(filter(table1, Table2[Start Value Reason] >= Table1[Start Value Batch]  && Table2[Start Value Reason] <= Table1[End Value Batch] ), Tabl1[Batch])