Apex Forge SQL Official Icon

English-to-SQL

Turn schema definitions plus natural language into verified SQL queries, executed against an in-memory SQLite sandbox with automated error self-correction.

Open @English-To-SQL on Poe →

What You Provide

Paste your CREATE TABLE statements (and optional INSERT sample rows), followed by your business question in plain English.

  • SQL DDL schema (tables, columns, types)
  • Optional sample rows for test results
  • Natural language query requirement

What You Receive

Syntactically verified SQL that ran without errors, accompanied by a real preview data table, execution timing, and dialect migration notes.

  • Guaranteed valid SQL verified by execution
  • Tabular Markdown result preview
  • Destructive query warnings (DROP/DELETE)

Copyable Starter Prompts

Paste these templates into the bot to see verified execution:

PROMPT 01 · TOP SPENDERS (AGGREGATION)
CREATE TABLE customers (id INT, name TEXT);
CREATE TABLE orders (id INT, customer_id INT, amount DECIMAL);
INSERT INTO customers VALUES (1, 'Alice'), (2, 'Bob');
INSERT INTO orders VALUES (101, 1, 150.00), (102, 2, 45.00);

Find the total spend for each customer, ordered by highest spend first.

Demonstrates GROUP BY, SUM, and JOIN verification.

PROMPT 02 · FILTERED DATE RANGES
CREATE TABLE expenses (id INT, category TEXT, amount DECIMAL, expense_date TEXT);
Show total spending for the 'Travel' category in August 2026.

Validates SQLite strftime and date filtering syntax.

PROMPT 03 · WINDOW FUNCTIONS
CREATE TABLE employees (id INT, department TEXT, salary INT);
Rank employees by salary within each department.

Generates PARTITION BY and RANK() window queries.

Verified Real Execution Output

Sample streamed response executing against in-memory SQLite:

### 📊 Verified SQL Query & Results

> ✅ Verified: Query successfully executed against an in-memory copy of your schema.

```sql
SELECT c.name, SUM(o.amount) AS total_spent
FROM customers c
JOIN orders o ON c.id = o.customer_id
GROUP BY c.id, c.name
ORDER BY total_spent DESC;
```

**Execution Time**: `0ms`

#### 📋 Tabular Output:
| name | total_spent |
| :--- | :--- |
| Alice | 150 |
| Bob | 45 |

Limitations & Responsible Use

Apex Forge SQL executes queries in an ephemeral in-memory SQLite sandbox using WebAssembly. It does not connect to your live databases or enterprise data warehouses. When porting generated queries to PostgreSQL, MySQL, or SQL Server, verify dialect-specific date formatting, full outer joins, and performance indexing before production rollout.

Frequently Asked Questions

How does Apex Forge SQL verify queries?

The engine instantiates an in-memory SQLite WebAssembly database, applies your CREATE TABLE schema, executes the generated SQL, and verifies the resulting tabular data.

Does Apex Forge SQL access my production database?

No. The bot operates purely on the schema and sample rows you paste into the chat. It has zero external database network connectivity.

What happens if a query contains DROP or DELETE statements?

The query runner detects destructive statements (DROP, TRUNCATE, DELETE without WHERE) and emits prominent safety warning banners.