solana.defi Table: ez_lending_borrows Type: Base Table
Description
This table captures borrow events across Solana DeFi lending protocols including Kamino and MarginFi. Each row represents a single borrowing transaction where users take loans against their deposited collateral. The data includes enriched transaction details with USD pricing, token metadata, and protocol identification, supporting comprehensive analytics on lending market demand-side activity and borrowing behavior patterns.Key Use Cases
- Track borrowing activity and capital utilization across lending protocols
- Analyze user borrowing patterns and leverage strategies
- Monitor borrowed asset composition and demand trends
- Study protocol usage and borrowing preference analysis
- Calculate borrowing costs and interest rate analysis
- Support credit risk assessment and loan performance tracking
Important Relationships
- Related to defi.ez_lending_depositsfor analyzing collateral backing borrowed amounts
- Related to defi.ez_lending_repaymentsfor tracking loan lifecycle and repayment behavior
- Related to defi.ez_lending_liquidationsfor analyzing defaults and risk events
- Connects to core.ez_transfersfor underlying asset movement verification
- Links to price.ez_prices_hourlyfor USD valuation and loan-to-value calculations
Commonly-used Fields
- block_timestamp: For time-series analysis and borrowing timing patterns
- platform,- protocol: For protocol-specific analysis and borrowing market share
- borrower: For user behavior analysis and borrowing pattern identification
- token_address,- token_symbol: For asset-specific borrowing demand analysis
- amount,- amount_usd: For borrowing volume analysis and market size metrics
- protocol_market: For market-specific borrowing rates and utilization tracking
Sample Queries
Daily borrowing volume by protocol
Top borrowed assets analysis
Wallet specific borrow analysis
User borrowing patterns
Protocol market share
Columns
| Column Name | Data Type | Description | 
|---|---|---|
| PLATFORM | TEXT | The name of the lending platform or protocol where the transaction occurred. This identifies the specific DeFi lending service provider. | 
YYYY-MM-DD HH:MI:SS (UTC). | | BLOCK_ID | NUMBER | A unique identifier for the
block in which this transaction was included on the Solana blockchain. Typically a sequential
integer or hash, depending on the data source. Used to group transactions by block and analyze
block-level activity.
Example:
- 123456789
- Supports block-level analytics, such as block production rate and transaction throughput.
- Useful for tracing transaction inclusion and block explorer integrations.
- All transactions with the same ‘block_id’ share the same ‘block_timestamp’. | | TX_ID | TEXT | The unique transaction signature (hash) for each transaction on the Solana blockchain. This field is a base58-encoded string, typically 88 characters in length, and serves as the primary identifier for transactions across all Solana data models. Used to join transaction data with related tables (blocks, events, transfers, logs, decoded instructions) and to trace the full lifecycle and effects of a transaction. Essential for transaction-level analytics, debugging, and cross-referencing with block explorers or Solana APIs.
- 5Nf6Q2k6v1Qw2k3v4Qw5Nf6Q2k6v1Qw2k3v4Qw5Nf6Q2k6v1Qw2k3v4Qw5Nf6Q2k6v1Qw2k3v4Qw
- Enables precise tracking, auditing, and attribution of on-chain activity
- Used for linking transactions to events, logs, and protocol actions
- Critical for compliance, monitoring, and analytics workflows | | INDEX | NUMBER | The position of the transfer event within the list of events for a given Solana transaction. Used to order and reference transfers within a transaction. Indexing starts at 0 for the first event.
- 0 (first transfer in the transaction)
- 2 (third transfer in the transaction)
- Enables reconstruction of transfer order and analysis of intra-transaction asset movement.
- Used to join, filter, or segment data for protocol analytics, error tracing, and event sequencing. | | INNER_INDEX | NUMBER | The position of the inner instruction or event within the list of inner instructions for a given Solana transaction. Used to order and reference nested (CPI) instructions. Indexing starts at 0 for the first inner instruction.
- 0
- 2
- Enables precise identification and ordering of nested program calls (Cross-Program Invocations) within a transaction.
- Critical for analyzing composability, protocol integrations, and the full execution path of complex transactions. | | PROGRAM_ID | TEXT | The unique public key (base58-encoded address) of a Solana program. This field identifies the on-chain program (smart contract) responsible for processing instructions, emitting events, or managing accounts. Used throughout Solana analytics models—including events, transactions, IDLs, and program activity tables—to join, filter, and analyze program-level data.
- “4Nd1mY…”
- “TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA”
- Used as a join key for program activity, deployments, events, and interface changes.
- Supports segmentation of activity by protocol, DEX, NFT marketplace, or other on-chain application. | | EVENT_TYPE | TEXT | A string categorizing the type of event or instruction, such as ‘transfer’, ‘mint’, ‘burn’, or protocol-specific actions.
- ‘transfer’
- ‘mint’
- ‘burn’
- Enables segmentation and filtering of on-chain activity for analytics and dashboards.
- Used to group and analyze protocol-specific actions and user behaviors.
- May be derived from decoded instruction data or protocol-specific logic. | | BORROWER | TEXT | The wallet address of the user who is borrowing assets from the lending protocol. This is the recipient of the borrowed funds who becomes responsible for repayment.
- SOL
- USDC
- Enables grouping and filtering of transfers by token.
- Supports analytics on asset flows, protocol usage, and user preferences. | | TOKEN_IS_VERIFIED | BOOLEAN | A flag indicating if the asset has been verified by the Flipside team. | | AMOUNT_RAW | NUMBER | Unadjusted amount of tokens as it appears on-chain before decimal precision adjustments are applied. This preserves the exact on-chain representation of the token amount for precise calculations and verification.
- USDC: 50.00(represents 50 USDC tokens)
- Used to analyze transaction volumes, user activity, and protocol flows.
- Supports aggregation of asset movement for analytics and reporting. | | AMOUNT_USD | FLOAT | The USD value of the transferred amount, calculated using the token price at the time of the transfer. This field enables value-based analytics and comparisons across different tokens.
- 123.45 (represents $123.45 USD)
- Used for tracking transaction volumes, wallet activity, and payment flows in USD terms.
- Supports analytics on large value transfers, protocol revenue, and user behavior. | | EZ_LENDING_BORROWS_ID | TEXT | A unique, stable identifier for each record in this table. The primary key (PK) ensures that every row is uniquely identifiable and supports efficient joins, lookups, and data integrity across models. The PK may be a natural key (such as a blockchain transaction hash) or a surrogate key generated from one or more fields, depending on the table’s structure and requirements. | | INSERTED_TIMESTAMP | TIMESTAMP_NTZ | | | MODIFIED_TIMESTAMP | TIMESTAMP_NTZ | |