bachiwallet6
Updated 2022-11-06
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
29
30
31
32
33
34
35
›
⌄
WITH wallet_dtls AS
(
SELECT payer,
proposer
FROM flow.core.fact_transactions t1
JOIN flow.core.fact_events t2
ON t1.tx_id = t2.tx_id
WHERE t1.block_timestamp >= Dateadd(month, -2, Getdate())
AND Lower(event_type) LIKE '%tokenswithdrawn%'
AND t1.tx_succeeded ilike 'true'
)
SELECT
CASE
WHEN payer ='0x18eb4ee6b3c026d2' THEN 'Dapper'
WHEN payer ='0x55ad22f01ef568a1' THEN 'Blocto'
WHEN payer= '0x94bb84386cfc3b5d' THEN 'Everbloom'
WHEN payer ='0xecfad18ba9582d4f' THEN 'Joyride'
WHEN payer = '0x8234007b36f8113c' THEN 'Monsoon'
WHEN payer = '0x39e42c67cc851cfb' THEN 'lilico'
WHEN payer = '0x1b65c33d7a352c61' THEN 'Cricket Moments'
WHEN payer = '0x4bbff461fa8f6192' THEN 'Fantastec'
ELSE NULL
END AS wallet_provider,
count (DISTINCT buyer) AS no_of_buyers,
count (DISTINCT nft_id) AS no_of_nfts_sold,
count (DISTINCT tx_id) AS no_of_sales
FROM flow.core.ez_nft_sales t1
JOIN wallet_dtls t2
ON t1.buyer = t2.proposer
WHERE block_timestamp >= dateadd(month, -2, getdate())
AND wallet_provider IS NOT NULL
GROUP BY
wallet_provider
Run a query to Download Data