I'm working on a graph type application and I'm looking to find the best solution within a x,y axis start to end point.
MySQL Data:
Say I have the following: starting_x: 200 starting_y: 150 ending_x: 500 ending_y: 605
So I'm wanting to find the closest match between the above numbers to the database.
My query I'm working with now:
SELECT * FROM `graph` ORDER BY `start_pos_x`,`start_pos_y`,`end_pos_x`,`end_pos_y` ASC
I know this is not even close to what I'm trying to do but i'm having a hard time finding a solution on here.
Thanks!