Query editor
select call_block_time, lead(net_oi, 1, 0) over (order by call_block_time) as net_oi, funding_ratefrom(select distinct call_block_time,cast(JSON_query(_market, 'strict $.longPositionSize' ) as double) /1e30 -cast(JSON_query(_market, 'strict $.shortPositionSize' ) as double) /1e30 as net_oi,cast(JSON_query(_market, 'strict $.currentFundingRate' ) as double) * 365 /1e18 as funding_ratefrom hmx_arbitrum.PerpStorage_call_updateMarketwhere call_success = True and cast(_marketIndex as varchar) = '21'order by 1 desc)where call_block_time > now() - interval '{{Last n month}}' month