superflyTable of the first part
    Updated 2022-08-18
    WITH base AS (SELECT*,CONCAT('0x', SUBSTR(topics [1] :: STRING, 27, 42)) AS pr,
    ethereum.public.udf_hex_to_int(
    topics [2] :: STRING) :: DATE AS l_times,
    regexp_substr_all(SUBSTR(DATA, 3, len(DATA)), '.{64}') AS segmented_data,
    ethereum.public.udf_hex_to_int(
    segmented_data [0] :: STRING) AS tokenID,ethereum.public.udf_hex_to_int(segmented_data [1] :: STRING)/pow(10,18) AS VALUE,
    ethereum.public.udf_hex_to_int(segmented_data [2] :: STRING) AS received,
    ethereum.public.udf_hex_to_int(segmented_data [3] :: STRING) AS TIMESTAMP
    FROM optimism.core.fact_event_logs
    WHERE topics [0] :: STRING = '0xff04ccafc360e16b67d682d17bd9503c4c6b9a131f6be6325762dc9ffc7de624'),
    tabel1 as (SELECT tx_hash,block_timestamp,contract_address,pr,l_times,tokenID,
    VALUE,received
    FROM base)SELECT DATE_TRUNC ('day' ,l_times ) as times,---times looked
    COUNT(DISTINCT tx_hash) as COUNT_transaction,-----uniqe
    COUNT(DISTINCT pr) as count_wallet,----uniqe
    SUM(value) as volume----totall volume
    FROM tabel1 GROUP BY times ORDER BY times
    Run a query to Download Data