SELECT * FROM tablename WHERE key = 12345 ORDER BY version;