How to Query Your Database With Plain English
How It Works
When you connect your database to the platform, the AI reads your entire schema: every table, column, data type, and relationship. It uses this understanding to translate your English questions into accurate SQL. The AI knows which tables to query, which columns to filter on, how to join related tables, and how to format the output.
You type your question in the query interface, and the AI generates a SQL statement behind the scenes. The query runs against your live database, and the results appear in a formatted table. You can see the generated SQL if you want to verify what ran, copy it for use elsewhere, or refine it manually.
What You Can Ask
Simple Lookups
Start with straightforward questions to find specific records. "Show me customer John Smith" or "find all products in the Electronics category" or "what orders were placed today." The AI handles the WHERE clauses and column selection automatically.
Aggregations and Summaries
Ask for totals, averages, counts, and groupings. "How many orders did we get each month this year" or "what is the average order value by state" or "which product has the most returns." The AI writes GROUP BY queries with the right aggregate functions.
Multi-Table Queries
Questions that span multiple tables work naturally. "Show me customer names with their most recent order date" or "list all products that have never been ordered." The AI uses your foreign keys and relationships to write the correct JOIN statements.
Date and Time Filtering
The AI understands relative time references. "Orders from last week," "customers who signed up in January," "transactions from the last 30 days," and "sales year to date" all translate into the correct date comparisons for your database.
Complex Analysis
For deeper analysis, you can ask multi-part questions. "Compare sales this quarter to last quarter by product category" or "show me customers who bought product A but not product B" or "what percentage of support tickets were resolved within 24 hours." The AI handles subqueries, CTEs, and window functions as needed.
Tips for Better Results
- Use your actual column and table names when you know them. "Show me the orders table" is more precise than "show me purchases."
- Be specific about what you want to see. "Show me customer name, email, and order total" gives better results than "show me customer info."
- Start simple and refine. If the first query is not quite right, add more detail to your next question. The AI uses the conversation context to improve follow-up queries.
- Ask the AI to explain. If you want to understand the SQL it generated, ask "explain that query" and it will walk through the logic.
When the AI Gets It Wrong
Occasionally the AI might pick the wrong table or misinterpret an ambiguous question. When this happens, rephrase your question with more specific column or table names. You can also tell the AI "use the orders table, not the transactions table" to guide it. The more you use the system with your specific database, the more precise your questions become because you learn which terms map to which tables.
For technical details on how the AI reads and uses your schema, see How the AI SQL Assistant Understands Your Database Schema.
Ask questions about your data in plain English. Connect your database and start querying in minutes.
Get Started Free