amirkhannoriiCount number of arbitrage swaps
Updated 2022-05-02
99
1
2
3
4
5
6
7
8
9
10
11
›
⌄
select count(case when (swap_to_amount/swap_from_amount)>=1.01 then tx_id END) as The_number_of_swap_with_more_than_1percent_gain,
count (distinct tx_id) as The_number_of_all_Swaps,
(The_number_of_swap_with_more_than_1percent_gain/The_number_of_all_Swaps)*100 as "The percentage of all Swaps with more than 1 perecent gain"
from solana.swaps
where block_timestamp::date >= '2022-02-01'
and swap_program = 'jupiter aggregator v2'
and succeeded = 'True'
and (swap_from_mint = 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v' or swap_from_mint = 'Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB')
and (swap_to_mint = 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v' or swap_to_mint = 'Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB')
and swap_from_amount >=100
and swap_to_amount >=100
Run a query to Download Data