vscode-postgres
vscode-postgres copied to clipboard
Connection options lost when reopening unstored query after restart of VS Code
Steps to reproduce
- PostgreSQL: New query
- PostgreSQL: Selection connection ... Choose Postgres server + database
- Enter your query
- Developer: Reload Window
Expected behavior
Query can be run again without further configuration.
Actual behavior
"No PostgreSQL Server or Database selected". You need to choose Postgres server + database again.
Would be nice if this extension could memorize these settings per query. I often restart my editor.
This is possible by setting the default connection and default database in the extension settings.
sort of - that only really works if the query originally used the default connection - if the user changed the server/database before closing - it would reset to the defaults.
as you switch query tabs it does in fact remember the setting per query... however getting that to persist through a reload would be tricky...