Archive for February, 2009

Selecting closest values in MySQL

Monday, February 2nd, 2009

Sometimes the need arises to select several values in the vicinity of a certain value, preferably ordered by proximity. The values might be dates, zip-codes or any other meaningfully ordered values that can be represented as numerical values. How can we pull this off in MySQL?
(more...)