EVM Events

The core EVM blockchain data collection

Availability

This collection is available for Ethereum, Polygon, Arbitrum, Base and BSC.

Mapping rules

The table is wide and sparse. Each event's input is stored in a column named after its index in the input list and its derived type.

The column's name for a given input is derived as such: input_index_value_type

We support events with up to 12 inputs.

The mapping rules used to derive an input type from an ABI type are specified in the table below.

Here is how we store the various inputs of Transfer event:

Transfer(to address, from address, amount uint256))

  • to value is stored in the column input_0_value_address

  • from value is stored in the column input_1_value_address

  • amount is stored in the column input_2_value_uint256

Table Schema

Usage

The query below make use of the evm_events_ethereum_mainnet_v1 table to retrieve the number of transfers and the amount transferred for each day since the beginning of the year, for USDC (0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48).

select 
    date_trunc('day', timestamp) as t, 
    count(*) as count, 
    sum(input_2_value_uint256) as amount 
from evm_events_ethereum_mainnet_v1 
where 
    address = '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48' 
    and signature = 'Transfer(address,address,uint256)' 
    and timestamp >= '2023-01-01' 
group by t 
order by t desc

Last updated