alirsw10-l-p-02
    Updated 2022-08-25
    WITH lp as (
    SELECT
    to_char(block_timestamp::date, 'yyyy-mm-dd') as date,
    tx_id,
    TX_FROM_ADDRESS as wallet
    FROM
    ethereum.events_emitted
    WHERE
    TX_TO_ADDRESS = '0xd9e1ce17f2641f24ae83637ab66a2cca9c378b9f'
    and event_name = 'Transfer'
    and EVENT_INPUTS :
    from
    :: string = '0x0000000000000000000000000000000000000000'
    and TX_SUCCEEDED = 'TRUE'
    ),
    farmers as (
    SELECT
    to_char(block_timestamp::date, 'yyyy-mm-dd') as date,
    tx_id,
    TX_FROM_ADDRESS as wallet
    FROM
    ethereum.events_emitted
    WHERE
    TX_TO_ADDRESS = '0xef0881ec094552b2e128cf945ef17a6752b4ec5d'
    and event_name = 'Transfer'
    and EVENT_INPUTS :
    from
    :: string = TX_FROM_ADDRESS
    and EVENT_INPUTS : to :: string = '0xef0881ec094552b2e128cf945ef17a6752b4ec5d'
    and TX_SUCCEEDED = 'TRUE'
    )
    SELECT
    lp.date,
    COUNT(DISTINCT lp.wallet) as lps_Count,
    Run a query to Download Data