yolo_gamesVRF Spend vs VRF Recieve with AVGGasPrice and AVGGasUsage
Updated 2024-06-18
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 VRF Spend vs VRF Recieve @ https://flipsidecrypto.xyz/edit/queries/830ce047-d92a-4c74-bb74-58a73de801f6
-- forked from VRF Spend vs VRF Recieve @ https://flipsidecrypto.xyz/edit/queries/24917e34-c9f1-4ba3-952f-379bf079d016
with VRFandEntry as (
SELECT hour, SUM(Value) as VRFandEntryValue FROM (
SELECT DATE_TRUNC('hour', BLOCK_TIMESTAMP) as hour, SUM(AMOUNT_PRECISE) as Value FROM blast.core.ez_native_transfers
WHERE ORIGIN_TO_ADDRESS = LOWER('0x96648d17c273A932197aCF2232653Bed7D69EC6f') AND TO_ADDRESS = LOWER('0x96648d17c273A932197aCF2232653Bed7D69EC6f')
GROUP BY 1
UNION ALL
SELECT DATE_TRUNC('hour', BLOCK_TIMESTAMP) as hour, SUM(AMOUNT_PRECISE) as Value FROM blast.core.ez_native_transfers
WHERE ORIGIN_TO_ADDRESS = LOWER('0xA596f7D6587DE656d0Ef099d2F28fe699060BF97') AND TO_ADDRESS = LOWER('0xA596f7D6587DE656d0Ef099d2F28fe699060BF97')
GROUP BY 1
UNION ALL
SELECT DATE_TRUNC('hour', BLOCK_TIMESTAMP) as hour, SUM(AMOUNT_PRECISE) as Value FROM blast.core.ez_native_transfers
WHERE ORIGIN_TO_ADDRESS = LOWER('0xc6f17f7935B12a38fe4a80f4f4Db7DBaf324224c') AND TO_ADDRESS = LOWER('0xc6f17f7935B12a38fe4a80f4f4Db7DBaf324224c')
GROUP BY 1
)
GROUP BY 1
),
Entry as (
SELECT hour, SUM(valueplayed) as EntryValue FROM (
SELECT DATE_TRUNC('hour', BLOCK_TIMESTAMP) as hour, SUM(DECODED_LOG['numberOfRounds']*DECODED_LOG['playAmountPerRound']/1E18) as valueplayed FROM blast.core.ez_decoded_event_logs
WHERE EVENT_NAME = 'Flipper__GameCreated'
AND DECODED_LOG['currency'] != '0xf77dd21c5ce38ac08786be35ef1d1dec1a6a15f3'
GROUP BY 1
UNION ALL
SELECT DATE_TRUNC('hour', BLOCK_TIMESTAMP) as hour, SUM(DECODED_LOG['numberOfRounds']*DECODED_LOG['playAmountPerRound']/1E18) as valueplayed FROM blast.core.ez_decoded_event_logs
WHERE EVENT_NAME = 'Quantum__GameCreated'
AND DECODED_LOG['currency'] != '0xf77dd21c5ce38ac08786be35ef1d1dec1a6a15f3'
GROUP BY 1
UNION ALL
SELECT DATE_TRUNC('hour', BLOCK_TIMESTAMP) as hour, SUM(DECODED_LOG['numberOfRounds']*DECODED_LOG['playAmountPerRound']/1E18) as valueplayed FROM blast.core.ez_decoded_event_logs
WHERE EVENT_NAME = 'LaserBlast__GameCreated'
AND DECODED_LOG['currency'] != '0xf77dd21c5ce38ac08786be35ef1d1dec1a6a15f3'
QueryRunArchived: QueryRun has been archived