Text-to-SQL for Azure Database for PostgreSQL
Connect your Azure Database for PostgreSQL — Flexible Server or Single Server — to Chion and start asking questions in plain English. Chion generates verified SQL, runs it read-only, and renders interactive charts. Use port 5432 for direct connections or port 6432 for the built-in PgBouncer pooler.
Example question & SQL
See what Chion generates from a plain-English question.
You ask
"Top 10 customers by total spend this quarter"
Chion generates
SELECT
c.name,
SUM(o.total) AS total_spend
FROM customers c
JOIN orders o ON o.customer_id = c.id
WHERE o.created_at >= date_trunc('quarter', now())
GROUP BY c.name
ORDER BY total_spend DESC
LIMIT 10;Finding your Azure Database for PostgreSQL credentials
Azure Portal → your PostgreSQL server → Overview page
Azure Portal → your PostgreSQL server → Overview page
| Field | Where to Find | Default |
|---|---|---|
| Server (Host) | Overview page → Server name | <server>.postgres.database.azure.com |
| Port | Overview or Connection strings page | 5432 |
| Database | Created by default. Check via Connection strings or psql | postgres |
| Schema | Not in portal — default is public | public |
| User | Overview page → Admin username | What you set at creation |
| Password | Set at creation. Reset via Settings → Reset password | (not retrievable) |
Quick steps
- 1.Log in at portal.azure.com
- 2.Search for "Azure Database for PostgreSQL servers"
- 3.Click your server name
- 4.On the Overview page: copy the Server name (this is your host) and note the Admin username
- 5.Click Connection strings in the left sidebar for pre-built connection strings
- 6.Password is what you set during creation — reset via Settings → Reset password if needed
Azure Flexible Server uses port 5432 for direct connections and 6432 for the built-in PgBouncer pooler.
Open Azure Database for PostgreSQL consoleAzure Database for PostgreSQL troubleshooting
Common issues and how to fix them.
Port mismatch — 5432 vs 6432
Azure Flexible Server uses port 5432 for direct connections and port 6432 for the built-in PgBouncer pooler. If you copied the pooler connection string, make sure you also use port 6432 in Chion.
Firewall rule blocking connection
In the Azure Portal, go to your PostgreSQL server → Networking → add a firewall rule allowing the Chion IP range. For initial testing, enable "Allow public access from any Azure service".
Password reset
Go to your server → Settings → Reset password. The new password takes effect immediately.
Your credentials are encrypted
All connection credentials are encrypted with AES-256-GCM and stored in an isolated vault. Chion connects with read-only permissions — no INSERT, UPDATE, or DELETE is ever possible. Row-level security policies are honored on every query.
Read our security modelFrequently asked questions
Common questions about using Chion with Azure Database for PostgreSQL.
Does Chion work with Azure Flexible Server?
Can I use the built-in PgBouncer?
Does Chion support Azure Private Link?
Ready to connect your Azure Database for PostgreSQL database?
Open Chion, enter your credentials, and start asking questions in plain English.
Start your trial