Get started with PG Studio
Learn how to open PG Studio and run your first queries.
Prerequisites
To use PG Studio, you need:
- Aiven permissions: The
service:data:writepermission at the organization, unit, or project level. This permission is included in the Admin, Developer, and Operator roles. - Network access: Your IP address must be in the service's IP allowlist. PG Studio validates your browser's IP address, which must be allowed in the service's IP filter configuration. If you get the
Access is not allowed from the IP addresserror, add your IP address to the allowlist.
Open PG Studio
- In the Aiven Console, open your Aiven for PostgreSQL service.
- Click PG Studio.
- Select the source database and schema.
PG Studio opens a split view that shows the SQL editor and the AI Assistant panel. Use the editor selectors to change the database source and schema.
Run your first query
You can write SQL directly or use the AI Assistant to generate queries:
Write SQL manually
-
In the SQL editor, enter your query, for example:
SELECT * FROM users LIMIT 10; -
Click Run.
-
View the results in the results panel.
Generate SQL with AI
- In the AI Assistant panel, describe what you need, for example: Show all users who signed up in the last 7 days.
- Review the generated SQL in the SQL editor.
- Click Run to execute the query.
Explore your schema
- Click Open schema map to view your database structure as an interactive diagram.
- Browse tables, columns, and relationships.
- Ask schema questions in the AI Assistant panel, such as How are the orders and customers tables related?.