Abolfazl_771025opensea
Updated 2023-03-15
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
›
⌄
with main as( SELECT
instruction:accounts as user,
TX_ID,
COALESCE(inner_instruction:instructions[4]:parsed:info:lamports * POWER(10, -9), 0) AS platform_fee,
COALESCE(inner_instruction:instructions[5]:parsed:info:lamports * POWER(10, -9), 0) AS collection_royalty
FROM solana.core.fact_events e
LEFT JOIN solana.core.dim_labels l ON l.address = inner_instruction:instructions[0]:parsed:info:mint::string
where instruction:programId = 'hausS13jsjafwWwGqZTUQRmWyvyxn9EQpqMwV1PBBmk'
)
select
'opensea' as platform,
'0% royalty' as royalty,
count(tx_id) as tx_count,
count(DISTINCT user) as user_count
from main
where collection_royalty = '0'
and platform_fee = '0'
group by 1,2
union
select
'opensea' as platform,
'more than 0% royalty' as royalty,
count(tx_id) as tx_count,
count(DISTINCT user) as tx_count
from main
where collection_royalty > '0'
and platform_fee > '0'
group by 1,2
Run a query to Download Data