WITH SimpleTable (ID, Type, Value) AS (
SELECT 1, 'A', 1 FROM dual UNION ALL
SELECT 1, 'B', 2 FROM dual UNION ALL
SELECT 1, 'C', 3 FROM dual UNION ALL
SELECT 2, 'A', 4 FROM dual UNION ALL
SELECT 2, 'B', 5 FROM dual UNION ALL
SELECT 2, 'C', 6 FROM dual)