Re: are views typically any faster/slower than equivilent joins?
В списке pgsql-performance по дате отправления:
| От | Bruno Wolff III |
|---|---|
| Тема | Re: are views typically any faster/slower than equivilent joins? |
| Дата | |
| Msg-id | 20030601054337.GD16259@wolff.to обсуждение исходный текст |
| Ответ на | Re: are views typically any faster/slower than equivilent joins? (Rod Taylor <rbt@rbt.ca>) |
| Ответы |
Re: are views typically any faster/slower than
|
| Список | pgsql-performance |
On Sun, Jun 01, 2003 at 00:02:39 -0400, Rod Taylor <rbt@rbt.ca> wrote: > > Some views such as unions will not be as fast as you would like, but > thats a general issue with PostgreSQLs inability to throw away selects > when it won't find results on one side of a union. > > CREATE VIEW sales AS SELECT * FROM sales_archive_2002 UNION ALL SELECT * > FROM sales_current; > > > SELECT * FROM sales WHERE timestamp => CURRENT_TIMESTAMP - INTERVAL '1 > day'; > > The above query would not be so quick. I thought some work had been done on pushing where conditions down into unions? If so the above wouldn't be too bad. It would still look at the archive table, but it should return no rows relatively quickly assuming an appropiate index exists.
В списке pgsql-performance по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера