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

# Ledgers V2

### Table Details

| Property            | Value                    |
| ------------------- | ------------------------ |
| Table Name          | `stellar.raw.ledgers_v2` |
| Table Status        | Production-Ready         |
| Unique Key          | `sequence`               |
| Clustering Key(s)   | `to_date("close_time")`  |
| Search Optimization | `sequence`               |

### Table Columns

| Column Name                         | Data Type         | Description                                                                                    |
| ----------------------------------- | ----------------- | ---------------------------------------------------------------------------------------------- |
| sequence                            | NUMBER(38,0)      | Stellar ledger sequence number (ledger height).                                                |
| close\_time                         | TIMESTAMP\_NTZ(9) | Time when this ledger was closed and finalized by the network.                                 |
| hash                                | VARCHAR(16777216) | Hash of this ledger.                                                                           |
| base\_fee                           | NUMBER(38,0)      | Base fee per operation in stroops at this ledger.                                              |
| base\_reserve                       | NUMBER(38,0)      | Minimum XLM balance required per ledger entry, in stroops, at this ledger.                     |
| id\_pool                            | NUMBER(38,0)      | Last used generalized ledger entry ID in this ledger header.                                   |
| inflation\_seq                      | NUMBER(38,0)      | Sequence number tracking the inflation process for this ledger.                                |
| fee\_pool                           | NUMBER(38,0)      | Accumulated fee pool balance in the network at this ledger close, in stroops.                  |
| total\_coins                        | NUMBER(38,0)      | Total XLM supply in the network at this ledger close, in stroops.                              |
| previous\_ledger\_hash              | VARCHAR(16777216) | Hash of the previous ledger.                                                                   |
| extension                           | VARCHAR(16777216) | XDR extension data on this ledger header, used for forward-compatible ledger changes.          |
| node\_id                            | VARCHAR(16777216) | Identifier of the validator node that proposed this ledger.                                    |
| signature                           | VARCHAR(16777216) | Signature over this ledger header.                                                             |
| skip\_list                          | VARIANT           | Array of ledger hashes at exponentially-spaced offsets, used for efficient historical lookups. |
| bucket\_list\_hash                  | VARCHAR(16777216) | Hash of the bucket list (Stellar's persistent state storage) after applying this ledger.       |
| max\_tx\_set\_size                  | NUMBER(38,0)      | Maximum number of transactions allowed in this ledger's transaction set.                       |
| tx\_set\_hash                       | VARCHAR(16777216) | Hash of the transaction set included in this ledger.                                           |
| tx\_set\_result\_hash               | VARCHAR(16777216) | Hash of the execution results for the transaction set in this ledger.                          |
| upgrades                            | VARCHAR(16777216) | Array of protocol upgrade votes included in this ledger close.                                 |
| total\_byte\_size\_of\_bucket\_list | NUMBER(38,0)      | Total size in bytes of the bucket list (Stellar's persistent state) at this ledger.            |
| protocol\_version                   | NUMBER(38,0)      | Stellar protocol version in effect at this ledger.                                             |
| transaction\_count                  | NUMBER(38,0)      | Number of transactions included in this ledger.                                                |
| successful\_transaction\_count      | NUMBER(38,0)      | Number of transactions in this ledger that executed successfully.                              |
| failed\_transaction\_count          | NUMBER(38,0)      | Number of transactions in this ledger that failed execution.                                   |
| operation\_count                    | NUMBER(38,0)      | Number of operations across all transactions in this ledger.                                   |
| effect\_count                       | NUMBER(38,0)      | Number of effects (state change records) produced in this ledger.                              |
| contract\_event\_count              | NUMBER(38,0)      | Number of contract events emitted in this ledger.                                              |
| diagnostic\_event\_count            | NUMBER(38,0)      | Number of diagnostic events emitted during Soroban execution in this ledger.                   |
| metadata                            | VARIANT           | Ledger metadata.                                                                               |
| \_extra\_fields                     | VARIANT           | Catch-all of additional source fields not mapped to a dedicated column.                        |
| \_created\_at                       | TIMESTAMP\_NTZ(9) | Timestamp of when the entry was created in the database.                                       |
| \_updated\_at                       | TIMESTAMP\_NTZ(9) | Timestamp of when the entry was last updated in the database.                                  |
| token\_transfer\_count              | NUMBER(38,0)      | Number of token transfer events emitted in this ledger.                                        |
| balance\_snapshot\_count            | NUMBER(38,0)      | Number of balance snapshot records associated with this ledger.                                |
| event\_count                        | NUMBER(38,0)      | Number of events emitted in this ledger.                                                       |
