Re: Views "missing" from information_schema.view_table_usage

From: Erik Wienhold <ewie(at)ewie(dot)name>
To: Jonathan Lemig <jtlemig(at)gmail(dot)com>, "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Views "missing" from information_schema.view_table_usage
Date: 2022-12-02 22:14:05
Message-ID: 1540400959.42131.1670019245837@office.mailbox.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs pgsql-general

> On 02/12/2022 22:55 CET Jonathan Lemig <jtlemig(at)gmail(dot)com> wrote:
>
> drps=> select viewowner, schemaname, viewname from pg_views where viewname = 'platform_version_v';
>  viewowner | schemaname | viewname
> -----------+------------+--------------------
>  drps | event | platform_version_v
> (1 row)
>
> drps=> select * from information_schema.view_table_usage where view_name = 'platform_version_v';
>  view_catalog | view_schema | view_name | table_catalog | table_schema | table_name
> --------------+-------------+-----------+---------------+--------------+------------
> (0 rows)
>
> The event.platform_version_v doesn't show up when querying the view_table_usage view.

Does platform_version_v reference any tables? That view name suggests that it
provides some version info, e.g. with a definition like:

create view event.platform_version_v as select '1.0.0' as version;

In that case it won't appear in view_table_usage.

--
Erik

In response to

Browse pgsql-docs by date

  From Date Subject
Next Message Jonathan Lemig 2022-12-02 22:14:54 Re: Views "missing" from information_schema.view_table_usage
Previous Message Erik Wienhold 2022-12-02 22:08:11 Re: Views "missing" from information_schema.view_table_usage

Browse pgsql-general by date

  From Date Subject
Next Message Jonathan Lemig 2022-12-02 22:14:54 Re: Views "missing" from information_schema.view_table_usage
Previous Message Erik Wienhold 2022-12-02 22:08:11 Re: Views "missing" from information_schema.view_table_usage