> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dune.com/llms.txt
> Use this file to discover all available pages before exploring further.

# sophon.transactions

> Every transaction on Sophon — from, to, value, gas, calldata, and receipt status.

export const TableSample = ({tableName, tableSchema}) => <>
    <div className="hidden dark:block">
      <iframe src={`https://dune.com/embeds/3419983/5785629?table_schema_t6f0df=${tableSchema}&table_name_t6f0df=${tableName}&darkMode=true`} style={{
  width: '100%',
  height: '500px',
  border: 'none',
  marginTop: '10px'
}} />
    </div>
    <div className="dark:hidden">
      <iframe src={`https://dune.com/embeds/3419983/5785629?table_schema_t6f0df=${tableSchema}&table_name_t6f0df=${tableName}`} style={{
  width: '100%',
  height: '500px',
  border: 'none',
  marginTop: '10px'
}} />
    </div>
  </>;

export const TransactionsSnippet = ({blockchain}) => <div>
    <h2>Table Description</h2>
    <p>
      The <code>{blockchain}.transactions</code> table contains information about all transactions on the {blockchain} 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 {blockchain} blockchain. Transactions are created by users and are used to send value, deploy smart contracts, and interact with smart contracts.
    </p>
    <p>
    <Tip> 
      This is the raw version of this table. If the chain is a Fully Managed chain, decoded transaction calls will be available, see <a href={`/data-catalog/evm/${blockchain}/decoded/call-tables`}>call tables</a> section. If this is a Hosted chain, decoded call tables will not be available.
    </Tip>
    </p>
    <h2>Column Descriptions</h2>
    <table>
      <thead><tr><th>Column</th><th>Type</th><th>Description</th></tr></thead>
      <tbody>
        <tr><td><code>block_time</code></td><td><code>timestamp</code></td><td>Timestamp of the block containing this transaction</td></tr>
        <tr><td><code>block_number</code></td><td><code>bigint</code></td><td>Block number containing this transaction</td></tr>
        <tr><td><code>value</code></td><td><code>decimal</code></td><td>Amount of native token transferred (in wei)</td></tr>
        <tr><td><code>gas_limit</code></td><td><code>bigint</code></td><td>Maximum gas the sender is willing to use</td></tr>
        <tr><td><code>gas_price</code></td><td><code>bigint</code></td><td>Price per gas unit (in wei)</td></tr>
        <tr><td><code>gas_used</code></td><td><code>bigint</code></td><td>Actual gas consumed by the transaction</td></tr>
        <tr><td><code>max_fee_per_gas</code></td><td><code>bigint</code></td><td>Maximum total fee per gas (EIP-1559)</td></tr>
        <tr><td><code>max_priority_fee_per_gas</code></td><td><code>bigint</code></td><td>Maximum priority fee (tip) per gas (EIP-1559)</td></tr>
        <tr><td><code>priority_fee_per_gas</code></td><td><code>bigint</code></td><td>Actual priority fee per gas paid</td></tr>
        <tr><td><code>nonce</code></td><td><code>bigint</code></td><td>Transaction count of the sender before this transaction</td></tr>
        <tr><td><code>index</code></td><td><code>bigint</code></td><td>Position of the transaction within the block</td></tr>
        <tr><td><code>success</code></td><td><code>boolean</code></td><td>Whether the transaction executed successfully</td></tr>
        <tr><td><code>from</code></td><td><code>varbinary</code></td><td>Address of the transaction sender</td></tr>
        <tr><td><code>to</code></td><td><code>varbinary</code></td><td>Address of the transaction recipient</td></tr>
        <tr><td><code>block_hash</code></td><td><code>varbinary</code></td><td>Hash of the block containing this transaction</td></tr>
        <tr><td><code>data</code></td><td><code>varbinary</code></td><td>Calldata sent with the transaction</td></tr>
        <tr><td><code>hash</code></td><td><code>varbinary</code></td><td>Unique hash of the transaction</td></tr>
        <tr><td><code>type</code></td><td><code>varchar</code></td><td>Transaction type (legacy, EIP-2930, EIP-1559, EIP-4844)</td></tr>
        <tr><td><code>access_list</code></td><td><code>array(row)</code></td><td>List of addresses and storage keys accessed (EIP-2930)</td></tr>
        <tr><td><code>block_date</code></td><td><code>date</code></td><td>Date of the block (UTC)</td></tr>
        <tr><td><code>blob_versioned_hashes</code></td><td><code>array(varbinary)</code></td><td>Versioned hashes of blobs (EIP-4844)</td></tr>
        <tr><td><code>max_fee_per_blob_gas</code></td><td><code>bigint</code></td><td>Maximum fee per blob gas (EIP-4844)</td></tr>
        <tr><td><code>authorization_list</code></td><td><code>array(row)</code></td><td>Authorization list for EIP-7702 transactions</td></tr>
      </tbody>
    </table>
    <h2>Table Sample</h2>
    <TableSample tableSchema={blockchain} tableName="transactions" />
    <h2>Examples</h2>
    <h3>Show all transactions sent by a specific address</h3>
    <pre><code>{`SELECT * 
FROM ${blockchain}.transactions WHERE "from" = '0x50A1b5c358F8D34F0d35aA2f10742c46054E247e'
`}</code></pre>
    <h3>Count the number of transactions per block</h3>
    <pre><code>{`SELECT 
    block_number, 
    COUNT(*)
FROM ${blockchain}.transactions
GROUP BY 1
ORDER BY 1 DESC
LIMIT 10
`}</code></pre>
    <h3>Show the top 10 transactions with the highest gas price</h3>
    <pre><code>{`SELECT 
    hash, 
    gas_price
FROM ${blockchain}.transactions
ORDER BY gas_price DESC
LIMIT 10
`}</code></pre>
  </div>;

<TransactionsSnippet blockchain="sophon" />
