github.com/matrixorigin/matrixone@v1.2.0/pkg/sql/plan/tpch/q11.sql (about) 1 select 2 ps_partkey, 3 sum(ps_supplycost * ps_availqty) as value 4 from 5 partsupp, 6 supplier, 7 nation 8 where 9 ps_suppkey = s_suppkey 10 and s_nationkey = n_nationkey 11 and n_name = 'JAPAN' 12 group by 13 ps_partkey having 14 sum(ps_supplycost * ps_availqty) > ( 15 select 16 sum(ps_supplycost * ps_availqty) * 0.0001000000 17 from 18 partsupp, 19 supplier, 20 nation 21 where 22 ps_suppkey = s_suppkey 23 and s_nationkey = n_nationkey 24 and n_name = 'JAPAN' 25 ) 26 order by 27 value desc 28 ;