TablePro has a built-in AI chat panel for writing, explaining, and fixing SQL queries. It supports Claude (Anthropic), OpenAI, Gemini (Google), OpenRouter, Ollama, and custom OpenAI-compatible endpoints.
Type your question and press Enter. The AI receives your database type, schema (tables, columns, foreign keys), and current query, then responds with context-aware suggestions in Markdown with syntax-highlighted SQL code blocks.SQL code blocks in responses have Copy and Insert to Editor buttons. Token counts appear below each response for tracking API usage.
Conversations save automatically to disk and auto-title from your first message. Use the chat panel buttons to browse history, start a new conversation, or delete one.
Failed responses show a Retry button; successful ones have a Regenerate button to get a new answer.Responses stream in real-time. Click Stop to cancel. You can scroll up while typing a new message.
Click Add Provider, choose a type, enter your API key (endpoint pre-fills), specify a model or click Fetch to pull available models, then click Test to verify.
Route Chat, Explain Query, Optimize Query, Fix Error, and Inline Suggestions to different providers, or use the default (first enabled provider).
Configure what the AI receives in Settings > AI > Context: database schema (on), current query (on), query results (off), and max tables (20). More context improves answers but increases data sent.Set a per-connection AI policy (Use Default, Always Allow, Ask Each Time, or Never) to control access on sensitive connections.