0

I have Latitude and longitudes for UPS stores. Column a has UPS store code, Column b is the latitudes, Column c is the longitude. I also have another list of latitude (column e) and longitudes (column f) for random Walmart locations. I need to find the nearest set of coordinates of the Walmart and ups stores for shortest driving distance

=INDEX($A3ドル:$A434,ドル MATCH(MIN(SQRT((E11-B3ドル:B434ドル)^2+(F11-C3ドル:C434ドル)^2)), SQRT((E11-B3ドル:B434ドル)^2+(F11-C3ドル:C434ドル)^2), 0))

I tried this formula (very popular when I search for the solution-however, it works on my small sample data (rows of 10)- However when I try it on the data I need (400+ rows), every single cell returns #VALUE!

Attached is example of my sample data its working on

Ron Rosenfeld
62.1k7 gold badges35 silver badges72 bronze badges
asked Feb 15, 2024 at 19:01
6
  • 1
    Why should I not upload images of code/data/errors when asking a question? Commented Feb 15, 2024 at 20:45
  • 2
    Your formula will not provide driving distance. Commented Feb 15, 2024 at 20:51
  • 1
    Like Ron Rosenfeld commented: nearest location is not necessarily shortest driving distance, but most definately isn't equal to the distance. Commented Feb 15, 2024 at 21:44
  • 2
    I just tried your formula on 600 rows, and it worked perfectly. Without knowing your data we can't know why it doesn't work for you. Commented Feb 16, 2024 at 10:23
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. Commented Feb 29, 2024 at 8:46

0

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.