Re: Listing views - Mailing list pgsql-general

From Doug McNaught
Subject Re: Listing views
Date
Msg-id 87d61zghu6.fsf@asmodeus.mcnaught.org
Whole thread Raw
In response to Re: Listing views  (Olivier Guilyardi <ml@xung.org>)
Responses Re: Listing views
List pgsql-general
Olivier Guilyardi <ml@xung.org> writes:

> Okay, that's what I thought : an initial little query to identify the server
> version, so that subsequent queries can be adapted accordingly...
>
> But, since this "What Postgresql version is this ?" query is
> silently performed by the library I'm interested in, what the host
> application is not supposed to know, it must be ensured that it's
> not going to break : is version() the way to go ? Could there be
> some permission issues with very restrictive user accounts ?  Some
> better _only-one-query_ way to identify the server version/features
> ?

'SELECT version();' should work.  There will be no permission issues
with calling that function unless you set the database up that way--it
has PUBLIC execute permission by default.

-Doug
--
Let us cross over the river, and rest under the shade of the trees.
   --T. J. Jackson, 1863

pgsql-general by date:

Previous
From: "Rob Klaus"
Date:
Subject: Relation does not exist
Next
From: Olivier Guilyardi
Date:
Subject: Re: Listing views