Forum Discussion

Magpie_Rob's avatar
Magpie_Rob
Helper I
5 years ago
Solved

Distance Bins based on long and lat

Hello   So I have 2 tables, on with customers and there Longitude and Latitude and anotherone with Stores with there longitude and latitude - I'm trying to create a table with a list of the stores ...
  • parry2k's avatar
    5 years ago

    Magpie_Rob is this what you are looking for:

     

     

  • Magpie_Rob's avatar
    Magpie_Rob
    5 years ago

    This was the main bit! it worked really well thank you! 

    Store Distance Bins = 
    ADDCOLUMNS (
        CROSSJOIN (
            VALUES ( Store_Location[Postcode] ),
            VALUES ( 'Customers Locations'[id] )
        ),
        "Miles", [Miles],
    )