Search Postgresql Archives

Re: \dt doesn't show all relations in user's schemas (8.4.2)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Monday 21 December 2009 5:17:49 pm Scott Marlowe wrote:
> On Mon, Dec 21, 2009 at 6:14 PM, Tom Lane <tgl@xxxxxxxxxxxxx> wrote:
> > Scott Marlowe <scott.marlowe@xxxxxxxxx> writes:
> >> On Mon, Dec 21, 2009 at 6:10 PM, Tom Lane <tgl@xxxxxxxxxxxxx> wrote:
> >>> Well, yes, because only the first one is visible.  The second one is
> >>> masked by the first.
> >>
> >> But the docs say that ALL objects in the schema path will be shown.
> >> So, my point stands, either the docs are wrong, or the behaviour is.
> >> I'd think it's the docs.
> >
> > It says the *visible* objects will be shown.  Ones that are masked
> > aren't any more visible than if they were in some other schema
> > altogether: either way, if you want to reference such an object in
> > a SQL statement, you'd have to schema-qualify it.
>
> Ahh, right, it's about visibility.  Hadn't caught that part.

I think that is where the biggest misunderstanding lies. The problem is that 
people new to the database may not fully understand what visible means in this 
context. I know this tripped me up the first time I encountered the identical 
name situation. I made the same assumption the OP did, the tables where in the 
search_path and I had permissions on them so they should be 'visible'. It took 
some digging around to find the correct answer. I not sure how the best way is 
to clarify that in the psql documentation.

-- 
Adrian Klaver
aklaver@xxxxxxxxxxx

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux