Group by having count 1. Apache hive. apache spark. ручники из hadoop. select group.