On Sep 15, 10:28 am, dp...@postgresql.org (Dave Page) wrote:
> Rob McDonell wrote:
> > In both version 1.6 and 1.8 (can't remember earlier) the SQL button and
> > Query Tool menu item are inactive/greyed out when a Role is selected in
> > the Object Browser. This tool should always be available: regardless of
> > what you're browsing, you might want to write a query.
>
> They get disabled because there is no database associated with a role in
> which to start the query tool.
In a future release we could default to database "postgres" for global
objects, which is there for purposes like this one, isn't it?
It would be convenient to to open the SQL window directly from a role.
As long as we work on global objects like roles, the database does not
make a difference.
Of course, database "postgres" could be absent (pg versions < 7.4 or
dropped for some reason). We could further default to template1, but I
would rather warn the user that database "postgres" is missing and not
open the SQL window. We want to avoid trash in the template. And there
might be some potential for users to overlook what database they are
connected to, even if it is displayed clearly enough.
Still, I would definitely like the feature.
Regards
Erwin