Re: Postgres views cannot use both union and join/where

Поиск
Список
Период
Сортировка
От Michael Lewis
Тема Re: Postgres views cannot use both union and join/where
Дата
Msg-id CAHOFxGppNR3m4Dc-1nL-YA-sqWjSWs7JEx7EgoPnPKk_-7c5KA@mail.gmail.com
обсуждение исходный текст
Ответ на Postgres views cannot use both union and join/where  (Mithran Kulasekaran <mithranakulasekaran@gmail.com>)
Ответы Re: Postgres views cannot use both union and join/where  ("David G. Johnston" <david.g.johnston@gmail.com>)
Список pgsql-performance
On Tue, Oct 19, 2021 at 3:48 PM Mithran Kulasekaran <mithranakulasekaran@gmail.com> wrote:
create  view template_view (id, name, description, is_staged) as
select t.id,t.name, t.description, false as is_staged
from template t
left join template_staging ts on t.name = ts.name and ts.name is null

Does that work? I've only seen that type of logic written as-

left join template_staging ts on t.name = ts.name
where ts.name is null

В списке pgsql-performance по дате отправления:

Предыдущее
От: Benedict Holland
Дата:
Сообщение: Re: Postgres views cannot use both union and join/where
Следующее
От: "David G. Johnston"
Дата:
Сообщение: Re: Postgres views cannot use both union and join/where