blob: 0ffe2b08eb05fb0c9d324a1bda2a556d74a91916 [file] [log] [blame]
drop dataverse tpch if exists;
create dataverse tpch;
use dataverse tpch;
create type OrderType as closed {
o_orderkey: int32,
o_custkey: int32,
o_orderstatus: string,
o_totalprice: double,
o_orderdate: string,
o_orderpriority: string,
o_clerk: string,
o_shippriority: int32,
o_comment: string
}
create nodegroup group1 if not exists on nc1, nc2;
create dataset Orders(OrderType)
primary key o_orderkey on group1;
write output to nc1:"/tmp/push_limit.adm";
for $o in dataset('Orders')
where $o.o_totalprice > 100
order by $o.o_orderkey
limit 10 offset 5
return { "price": $o.o_totalprice, "date": $o.o_orderdate }