Skip to main content

Table Description

The transactions table contains information about all transactions on the Tron blockchain. Each row represents a single transaction and includes information such as block number, hash, timestamp, sender, recipient, value, gas, gas price, and more. Transactions are the fundamental unit of interaction with the Tron blockchain. Transactions are created by users and are used to send value, deploy smart contracts, and interact with smart contracts.

Table Schema

ColumnTypeDescription
block_timetimestamp(3)The exact UTC timestamp when the block containing this transaction was added to the chain
block_numberbigintThe sequential number of the block containing this transaction
valueuint256Amount of TRX sent from sender to recipient, measured in sun (1 TRX = 10^6 sun)
gas_limitbigintMaximum number of energy units this transaction can consume
gas_pricebigintPrice per unit of energy for this transaction, denominated in sun
gas_usedbigintActual amount of energy units consumed by this transaction’s execution
max_fee_per_gasbigintMaximum total amount per energy unit the initiator is willing to pay
max_priority_fee_per_gasbigintMaximum additional fee per energy unit the initiator is willing to pay as a tip
priority_fee_per_gasbigintActual additional fee per energy unit paid as a tip
noncebigintSequential number representing the count of transactions sent from the sender’s address
indexbigintPosition of this transaction within its containing block
successbooleanWhether the transaction executed successfully (true) or failed (false)
fromvarbinaryAddress of the account that initiated and signed this transaction
tovarbinaryAddress of the recipient account or contract for this transaction
block_hashvarbinaryUnique identifier (hash) of the block containing this transaction
datavarbinaryInput data for the transaction, which may include function calls or contract interaction data
hashvarbinaryUnique identifier (hash) of this specific transaction
typevarcharType of transaction indicating its structure and fee mechanism
access_listarray(row(address varbinary, storagekeys array(varbinary)))List of addresses and storage keys the transaction plans to access, used for energy optimization
block_datedateThe UTC date of the block in which this transaction was included

Table Sample

Examples

Show all transactions sent by a specific address

select * 
from tron.transactions where "from" = 0x50A1b5c358F8D34F0d35aA2f10742c46054E247e

Count the number of transactions per block

SELECT 
    block_number, 
    COUNT(*)
FROM tron.transactions
GROUP BY 1
ORDER BY 1 DESC
LIMIT 10

Show the top 10 transactions with the highest gas price

SELECT 
    hash, 
    gas_price
FROM tron.transactions
ORDER BY gas_price DESC
LIMIT 10