Quantcast
Channel: Desktop topics
Viewing all articles
Browse latest Browse all 217069

Power Query calc across two tables

$
0
0

Hi

 

I was looking for some help with a Query.  For each single row of the PostCode Table I would like to perform a calculation against every row of the Road Table and return the min value from the results list.

 

The calculation for each row is ((PostCode[GEOMETRY_X]-Road[GEOMETRY_X])*(PostCode[GEOMETRY_X]-Road[GEOMETRY_X])) - ((PostCode[GEOMETRY_Y]-Road[GEOMETRY_X])*(PostCode[GEOMETRY_Y]-Road[GEOMETRY_X]))

 

So the for each of the 370 lines in the PC table the calculation would be performed 245 times. I would like the minimum value to be returned along with the string from the NAME1 column of the Road table.

 

I have attached an example workbook here

 

Any help would be much appreciated.

 

Many thanks


Dave


Viewing all articles
Browse latest Browse all 217069

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>