Skip to main content
Glama
preview_table.md1.51 kB
# preview_table Quick preview of table contents without writing SQL. ## Parameters | Name | Type | Required | Default | Description | |------|------|----------|---------|-------------| | `table_name` | string | ✅ Yes | - | Table to preview (`DATABASE.SCHEMA.TABLE` or simple name) | | `limit` | integer | ❌ No | 100 | Maximum rows to return (minimum 1) | | `warehouse` | string | ❌ No | profile | Warehouse override (Snowflake identifier) | | `database` | string | ❌ No | profile | Database override (Snowflake identifier) | | `schema` | string | ❌ No | profile | Schema override (Snowflake identifier) | > Identifiers may be unquoted (e.g., `ANALYTICS.FINANCE.TRANSACTIONS`) or quoted (`"Sales Analytics"."Reporting"."Orders"`). Up to three segments are supported. ## Discovery Metadata - **Category:** `query` - **Tags:** `preview`, `table`, `metadata`, `sampling` - **Usage Examples:** 1. Preview `ANALYTICS.FINANCE.TRANSACTIONS` with a 20 row limit and analytics warehouse override. 2. Sample `PIPELINE_V2_GROOT_DB.PIPELINE_V2_GROOT_SCHEMA.DEX_TRADES_STABLE` with the default session context. ## Returns ```json { "statement": "SELECT * FROM customers LIMIT 100", "rowcount": 100, "rows": [...] } ``` ## Examples ```python # Simple preview preview_table(table_name="customers", limit=10) # With overrides preview_table( table_name="analytics.prod.sales", limit=500, warehouse="LARGE_WH" ) ``` ## Related - [execute_query](execute_query.md) - For complex queries

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Evan-Kim2028/igloo-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server