Query editor
with labeled as (selectcall_block_time,call_tx_hash,rad / 1e45 as amount,case srcwhen 0x9759a6ac90977b93b58547b4a71c78317f391a28 then 'DaiJoin'when 0x3c0f895007ca717aa01c8693e59df1e8c3777feb then 'UsdsJoin'when 0x3225737a9bbb6473cb4a45b7244aca2befdb276a then 'DaiUsds converter'when 0xa188eec8f81263234da3622a406892f3d630f98c then 'USDS PSM wrapper'else '(other)' end as src_name,case dstwhen 0x9759a6ac90977b93b58547b4a71c78317f391a28 then 'DaiJoin'when 0x3c0f895007ca717aa01c8693e59df1e8c3777feb then 'UsdsJoin'when 0x3225737a9bbb6473cb4a45b7244aca2befdb276a then 'DaiUsds converter'when 0xa188eec8f81263234da3622a406892f3d630f98c then 'USDS PSM wrapper'else '(other)' end as dst_namefrom maker_ethereum.vat_call_movewhere call_success = trueand call_block_time > now() - interval '1' dayand (src in (0x3225737a9bbb6473cb4a45b7244aca2befdb276a, 0xa188eec8f81263234da3622a406892f3d630f98c)or dst in (0x3225737a9bbb6473cb4a45b7244aca2befdb276a, 0xa188eec8f81263234da3622a406892f3d630f98c)))selectcall_block_time,src_name,dst_name,amount,casewhen src_name = 'DaiJoin' then 'DAI in (DAI burned -> credit)'when dst_name = 'UsdsJoin' then 'USDS out (credit -> USDS minted)'when src_name = 'UsdsJoin' then 'USDS in (USDS burned -> credit)'when dst_name = 'DaiJoin' then 'DAI out (credit -> DAI minted)'else 'other'end as leg,call_tx_hashfrom labeledorder by call_block_time desc, call_tx_hash;