MCP + SQL
Expose live SQL views as MCP tools for AI agents. RisingWave's PostgreSQL compatibility makes every materialized view discoverable through the Model Context Protocol — enabling agents to query fresh business data using natural language.
Why MCP
The Model Context Protocol (MCP) standardizes how AI agents discover, connect to, and query external data sources. For databases, MCP eliminates the need to build custom API wrappers — agents automatically discover available tables and views, understand their schemas, and construct queries using natural language.
| Factor | Static Database + MCP | RisingWave + MCP |
|---|---|---|
| Data Freshness | Static snapshots | Continuously updated |
| Tool Discovery | Manual definitions | Auto-discovered via schema |
| Query Interface | Custom API wrappers | Standard PostgreSQL SQL |
| Maintenance | API code per tool | SQL views only |
Use Cases
With MCP-connected materialized views, AI agents can answer real-time business questions, monitor live metrics, detect anomalies, and trigger actions — all through natural language conversations backed by continuously-updated SQL views that reflect the current state of your data.
Ask 'What are today's top-selling products?' and the agent queries a live materialized view that aggregates sales streams in real-time
Agents query streaming metrics views to detect anomalies, report on SLA compliance, and surface infrastructure issues conversationally
Support agents query per-customer materialized views to get real-time order status, behavioral signals, and personalized recommendations
Operations teams ask natural language questions about inventory, supply chain, or logistics — backed by views that process live event streams
Integration
RisingWave speaks PostgreSQL protocol natively. Any PostgreSQL MCP server connects to RisingWave, discovers materialized views through information_schema, and exposes them as queryable tools. Because views update continuously from streaming sources, agents always access current data — not stale snapshots.
Expose live materialized views as MCP tools for your AI agents.
Connect MCP to RisingWave