I am building a map-based xamarin app. I have a list of coordinates I save in a database. I want to query all of the coordinates that fall within x meters from a given starting coordinate. I just wanted to know how I can get the offset I need for the latitude and the longitude to formulate my query. I know how to get the distance between to coordinates but most of the other searches I got returned the same formula. Any help would be appreciated. Thank you very much!
I've checked out the following posts which were suggested as I made this post:
how to check radius of 10 meter from x,y position - from GPS
Calculating gps coordinate radius
EDIT
To specify the requirements further
I want to be able to end up with 2 ranges of numbers that I can use for a query like this
"SELECT * FROM tbl_Coordinates WHERE Lat >= {MIN_LAT_OFFSET} AND Lat <= {MAX_LAT_OFFSET} AND Lng >= {MIN_LNG_OFFSET} AND Lng<={MIN_LNG_OFFSET}"
I want to avoid querying all the coordinates in the db and checking the distance of all of them to see if they are within the radius.
EDIT 2
A new suggestion popped up in stackoverflow that seems promising here
If you guys have a better/more accurate answer I'm open to them. Thanks!