Skip to main content
Schema: somnia.defi Table: dim_stablecoins Type: Base Table

What

This table provides a dimensional view of verified stablecoins across EVM-compatible blockchains. It consolidates stablecoin metadata from various sources to create a unified reference table for identifying and analyzing stablecoin tokens.

Key Use Cases

  • Identifying stablecoin tokens in transaction and event data
  • Filtering DeFi activities to stablecoin-only transactions
  • Analyzing stablecoin adoption and distribution
  • Tracking verified stablecoin contracts across chains
  • Building stablecoin-specific metrics and dashboards

Important Relationships

  • Join with defi.ez_stablecoins_supply: Use contract_address for supply metrics

Commonly-used Fields

  • contract_address: Unique stablecoin token contract address
  • symbol: Token symbol (e.g., USDC, USDT, DAI)
  • name: Full token name
  • label: Combined symbol and name, as a stablecoin unique identifier
  • decimals: Number of decimal places for the token
  • is_verified: Verification status

Sample queries

-- Get unique stablecoins
SELECT 
    label AS stablecoin,
    COUNT(*) AS token_count
FROM <blockchain_name>.defi.dim_stablecoins
GROUP BY 1
ORDER BY 2 DESC;

-- Get all USDC variants
SELECT 
    contract_address,
    symbol,
    name,
    decimals
FROM <blockchain_name>.defi.dim_stablecoins
WHERE symbol LIKE '%USDC%'
ORDER BY symbol;

-- Check if specific address is a stablecoin
SELECT 
    contract_address,
    label,
    decimals
FROM <blockchain_name>.defi.dim_stablecoins
WHERE contract_address = LOWER('0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48');

Columns

Column NameData TypeDescription
CONTRACT_ADDRESSTEXTThe unique smart contract address of the stablecoin token. Example: ‘0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48’
SYMBOLTEXTThe symbol identifier for the stablecoin token. Example: ‘USDC’
NAMETEXTThe full name of the stablecoin token. Example: ‘USD Coin’
LABELTEXTA combined display label containing both symbol and name. Example: ‘USDC: USD Coin’
DECIMALSNUMBERThe number of decimal places used by the token contract. Example: 6
IS_VERIFIEDBOOLEANIndicates whether the stablecoin is verified by the Flipside team. Example: true
IS_VERIFIED_MODIFIED_TIMESTAMPTIMESTAMP_NTZIS_VERIFIED_MODIFIED_TIMESTAMP column
INSERTED_TIMESTAMPTIMESTAMP_NTZUTC timestamp when the record was first added to the Flipside database. Format: TIMESTAMP_NTZ Use Cases: Data freshness monitoring Incremental processing markers Debugging data pipeline issues SLA tracking Query Example:
MODIFIED_TIMESTAMPTIMESTAMP_NTZUTC timestamp of the most recent update to this record. Format: TIMESTAMP_NTZ Triggers for Updates: Data corrections Enrichment additions Reprocessing for accuracy Schema migrations Monitoring Usage:
DIM_STABLECOINS_IDTEXTPrimary key - unique identifier for each row ensuring data integrity. Format: Usually VARCHAR containing composite key generated using MD5 hash of the relevant columns. Example: MD5(blocknumber, txhash, trace_index) Usage: Deduplication in incremental loads Join operations for data quality checks Troubleshooting specific records Important: Implementation varies by table - check table-specific documentation.