Query editor
with nft_balance as(select id,sum(value) as balance from(selectid,-cast((value) as double) as valuefrom erc1155_ethereum.evt_TransferSinglewhere contract_address=0x76BE3b62873462d2142405439777e971754E8E77and "to"=0x0000000000000000000000000000000000000000and 1 <= {{Synchronize}}union allselectid,cast((value) as double) as valuefrom erc1155_ethereum.evt_TransferSinglewhere contract_address=0x76BE3b62873462d2142405439777e971754E8E77and "from"=0x0000000000000000000000000000000000000000union allselectid, -cast(value as double) as valuefrom erc1155_ethereum.evt_TransferBatchcross join unnest("ids","values") as tbl(id,value)where contract_address=0x76BE3b62873462d2142405439777e971754E8E77and "to"=0x0000000000000000000000000000000000000000union allselectid,cast(value as double) as valuefrom erc1155_ethereum.evt_TransferBatchcross join unnest("ids","values") as tbl(id,value)where contract_address=0x76BE3b62873462d2142405439777e971754E8E77and "from"=0x0000000000000000000000000000000000000000)group by 1)select "Parallel","Class",sum(balance) as balance from(select*from nft_balance nb left join query_3048276 mdon cast(nb.id as varchar)= cast(md."Token ID" as varchar)where nb.balance>0)where "Class" in ('First Edition','SE','PL')--where "Parallel" ='Augencore'group by 1,2