0

I have a table with latitude and longitude columns with 1000 rows

I want when I give latitude and longitude It should return a matching lat-long result

and if lat and long are not found in the database can give the nearest lat long from the database table

table


------------------------------------------------|
id | name |      lat        |       long|       |
---|------|-----------------|-------------------|
1  | test |27.988865824076 | 77.8523526316      |

I am passing in the request body

{
    "latitude": 27.98681188240762,
    "longitude": 77.86585050166316
}

and expecting ht nearest matching result

0 Answers0