Forum Discussion
Find and return intersection points between lines
- 1 year ago
replace
SELECTCOLUMNS ( IntersectionPointsTable, "Temperature", [Temperature], "GHGValue1", [GHGValue1], "GHGValue2", [GHGValue2] )with
CONCATENATEX( IntersectionPointsTable, [Temperature], ", ", [Temperature], ASC )
Thank you for the response, it seems to have that issue, now I get "No common join columns detected. The join function 'NATURALINNERJOIN' requires at-least one common join column.".
All temperatures column are linked to a temperature table (that just list all the temperature once)
Adjusted the start to consider the temperature table, assume relationship to the other two tables
IntersectionPoints =
VAR tbl =
Addcolumns(
Temperatures[temperature],
"GHGValue1",
Calculate( max( Table1[GHG value1])),
"GHGValue2",
Calculate( max( Table2[GHG value2]))
)
VAR IntersectionPointsTable =
FILTER (
ADDCOLUMNS (
Tbl,
"Difference", [GHGValue1] - [GHGValue2]
),
ABS ( [Difference] ) < 0.1
)
RETURN
SELECTCOLUMNS (
IntersectionPointsTable,
"Temperature", [Temperature],
"GHGValue1", [GHGValue1],
"GHGValue2", [GHGValue2]
)
- Simon_G1 year agoFrequent Visitor
Thank you for the reply. Unfortunatly I still have an error "The expression refers to multiple columns. Multiple columns cannot be converted to a scalar value"
- Deku1 year agoSuper User
replace
SELECTCOLUMNS ( IntersectionPointsTable, "Temperature", [Temperature], "GHGValue1", [GHGValue1], "GHGValue2", [GHGValue2] )with
CONCATENATEX( IntersectionPointsTable, [Temperature], ", ", [Temperature], ASC )- Simon_G1 year agoFrequent Visitor
Looks like it worked in the end. I just had to change Max to Sum.
Thank you!