Re: [ADMIN] Using Views as Tables
| От | David L |
|---|---|
| Тема | Re: [ADMIN] Using Views as Tables |
| Дата | |
| Msg-id | CANcS_tfyZui9t7vgx_F4FKgdxQJeLTXZ4y_T7t3pywfup1FjjQ@mail.gmail.com обсуждение исходный текст |
| Ответ на | [ADMIN] Using Views as Tables (David L <segedunum@actuaria.co.uk>) |
| Ответы |
Re: [ADMIN] Using Views as Tables
|
| Список | pgsql-admin |
Yes I know. That's the point.
On 9 Jan 2017 1:46 a.m., "Scott Marlowe" <scott.marlowe@gmail.com> wrote:
On Sun, Jan 8, 2017 at 11:35 AM, David L <segedunum@actuaria.co.uk> wrote:
> I agree that in theory this shouldn't happen as the query planner should be
> intelligent enough to take the base query out of the equation all together,
> but this happens on a server where there should be a plentiful supply of
> memory (32GB) and little enough activity that table data should remain
> cached.
I'm not sure you understand the underlying method for views in postgresql.
Select * from view;
is literally changed into
select * from (yourviewdef here).
I.e. the query planner does NOTHING different for a select from a view
than if you just run the query that makes the up the view by hand.
В списке pgsql-admin по дате отправления: