| От | mlw |
|---|---|
| Тема | sub queries and caching. |
| Дата | |
| Msg-id | 3B59CE9A.A9516E27@mohawksoft.com обсуждение исходный текст |
| Список | pgsql-hackers |
Take these queries: select * from foo as F, (select * from bar where name = 'bla') as B where F.name = B.name union all select * from foo as F, (select * from bar where name = 'bla') as B where F.type = B.type OR create temp table B as select * from bar where name = 'bla'; select * from foo as F, B where F.name = B.name union all select * from foo as F, B where F.type = B.type; drop table B; My question is, which would be more efficient, or is it a wash? (A note, I will be calling this from an external programming laguage, PHP, so the first query would be one Postgres pq_exec call, while the second query would be three separate calls.) -- 5-4-3-2-1 Thunderbirds are GO! ------------------------ http://www.mohawksoft.com
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера