freemartianIncrease Amount and Time
Updated 2024-06-06
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
›
⌄
-- Deposit 0x65fc3873 => Create_lock
-- Deposit 0xeff7a612 => Increase_unlock_time
-- Deposit 0x4957677c => Increase_amount
-- {Deposit 0x7142a6a6 => Increase_amount_and_time}
-----------------------------------------------------
-- {Deposit 0x2371eb23 => Withdraw_and_create_lock
-- Withdraw 0x2371eb23 => Withdraw_and_create_lock}
-- Withdraw 0x3ccfd60b => withdraw()
with optimism AS(
SELECT
block_timestamp,
tx_hash,
origin_from_address AS wallet_address,
event_name,
(CASE
WHEN origin_function_signature = '0x65fc3873' THEN 'Create_lock'
WHEN origin_function_signature = '0xeff7a612' THEN 'Increase_unlock_time'
WHEN origin_function_signature = '0x4957677c' THEN 'Increase_amount'
WHEN origin_function_signature = '0x7142a6a6' THEN 'Increase_amount_and_time'
WHEN origin_function_signature = '0x2371eb23' THEN 'Withdraw_and_create_lock'
WHEN origin_function_signature = '0x3ccfd60b' THEN 'withdraw'
END) AS function,
(CASE
WHEN event_name = 'Withdraw' THEN -decoded_log:value * POW(10, -18)
WHEN event_name = 'Deposit' THEN decoded_log:value * POW(10, -18)
END
) AS supply,
TO_TIMESTAMP(decoded_log:locktime)::date AS lock_time,
TIMEDIFF('day',block_timestamp::date,lock_time) AS "Duration(days)",
decoded_log,
'Optimism' AS chain
FROM
optimism.core.ez_decoded_event_logs
WHERE
QueryRunArchived: QueryRun has been archived