/* syntax version 1 */
select key, Min(subkey) as subkey, Max(value) as value from plato.Input group by key order by key;