Introduction
Developing PostgreSQL solutions in Visual Studio Code involves more than writing SQL queries. Developers need to connect to databases, explore schemas and tables, run queries, and review results as part of their daily work. The PostgreSQL extension provides these capabilities directly inside Visual Studio Code. GitHub Copilot builds on this experience by offering AI-assisted help that uses the context of the connected PostgreSQL database.
Together, the PostgreSQL extension and GitHub Copilot support common PostgreSQL development tasks without requiring developers to switch to separate database tools. This approach keeps database work close to application code and helps teams stay focused while developing, testing, and refining PostgreSQL solutions.
Consider a rental agency called Margie’s Travel. The development team builds and maintains applications that rely on Azure Database for PostgreSQL to manage listings, reservations, and customer reviews. Their day-to-day work includes inspecting tables, writing and testing queries, investigating unexpected results, and refining SQL to meet application requirements. By using the PostgreSQL extension and GitHub Copilot inside Visual Studio Code, the Margie’s Travel team can explore database objects, generate and adjust SQL queries, and review results while working in a single development environment.
After completing this module, you’ll be able to:
- Explain how the PostgreSQL extension adds PostgreSQL database capabilities to Visual Studio Code.
- Describe how GitHub Copilot integrates with the PostgreSQL extension to provide database-aware assistance.
- Use Copilot Chat to generate and refine SQL queries based on natural-language prompts.
- Execute SQL queries and review results using the PostgreSQL extension’s built-in tools.