alexmcculloughPolygon Flow
Updated 2024-11-14
999
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
36
›
⌄
-- Query to track Coinbase flows on the Optimism blockchain
-- Ensures each wallet address is only tracked once
-- Includes labels from Ethereum, Base, Optimism, and Arbitrum
-- Includes transfers involving 'hot_wallet' and 'deposit_wallet' addresses
-- Excludes internal transfers and transfers involving other label_subtypes
WITH all_labels AS (
-- Combine labels from multiple chains and assign a priority to each blockchain
SELECT address, project_name, label_subtype
FROM (
SELECT
'ethereum' AS blockchain,
address,
label AS project_name,
label_subtype,
1 AS blockchain_priority
FROM ethereum.core.dim_labels
UNION ALL
SELECT
'base' AS blockchain,
address,
project_name,
label_subtype,
2 AS blockchain_priority
FROM base.core.dim_labels
UNION ALL
SELECT
'optimism' AS blockchain,
address,
project_name,
label_subtype,
3 AS blockchain_priority
QueryRunArchived: QueryRun has been archived