Query editor
selectcount(distinct l.user) as user_count, count(l.evt_tx_hash) as liq_count, count(distinct l.liquidator) as liquidator_count, sum(cast(l.liquidatedCollateralAmount as double) / pow(10,COALESCE(tk_col.decimals,18)) * p_col.price) as liq_usd_amountfrom aave_v2_ethereum.LendingPool_evt_LiquidationCall lLEFT JOIN tokens.erc20 tk_col ON tk_col.contract_address = l.collateralAssetLEFT JOIN prices.usd p_col ON p_col.minute = date_trunc('minute',l.evt_block_time) AND p_col.blockchain = 'ethereum' AND p_col.contract_address = l.collateralAssetwhere date_trunc('day',l.evt_block_time) >= cast('{{start_date}}' as timestamp)and date_trunc('day',l.evt_block_time) <= cast('{{end_date}}' as timestamp)-- first liquidation was on 2020-12-17 14:19 (evt_tx_hash: 0x9ef1c383398cee036a85ca024db051b7a1c8bc692e703fe1b230da9e2305eb4a)