Skip to content

Instantly share code, notes, and snippets.

View bkempner's full-sized avatar

Ben Kempner bkempner

  • Auto List
  • Austin, TX
View GitHub Profile
SELECT lat, lon, SQRT( POW( 69.1 * ( lat - 33.673989 ) , 2 ) + POW( 69.1 * ( 111.858430 - lon ) * COS( lat / 57.3 ) , 2 ) ) AS distance FROM cities where distance < 25 ORDER BY distance;