StangFAST002 - overview
Updated 2023-10-15Copy Reference Fork
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
36
›
⌄
-- forked from 001 - overview @ https://flipsidecrypto.xyz/edit/queries/21618bc0-5214-4ac6-89d2-1393c8223b7c
with
degen_ape AS
(
SELECT
a.contract_address AS ca
, a.token_name AS tn
, a.token_id AS ti
FROM
solana.nft.dim_nft_metadata a
WHERE
a.token_name = 'Degen Apes'
)
,
price AS
(
SELECT
date_trunc( 'day' , a.recorded_hour ) AS dt
, avg( a.close ) AS pr
, a.symbol AS sb
FROM
solana.price.fact_token_prices_hourly a
WHERE
a.symbol = 'SOL'
GROUP BY 1 , 3
ORDER BY 1 DESC
)
,
final AS
(
SELECT
date_trunc( '{{period}}' , a.block_timestamp ) AS "date"
, count( distinct a.purchaser ) AS "purchasers"
Run a query to Download Data