Re: [HACKERS] Early evaluation of constant expresions (with PATCH)
| От | Bruce Momjian |
|---|---|
| Тема | Re: [HACKERS] Early evaluation of constant expresions (with PATCH) |
| Дата | |
| Msg-id | 199909220217.WAA23935@candle.pha.pa.us обсуждение исходный текст |
| Ответ на | Re: [HACKERS] Early evaluation of constant expresions (with PATCH) (Tom Lane <tgl@sss.pgh.pa.us>) |
| Список | pgsql-hackers |
> Bernard Frankpitt <frankpit@pop.dn.net> writes: > > The solution that I propose is to include code in the optimizer that > > picks functions with constant arguments out of a qualification > > clause, and evaluates them. > > This is something I had on my own to-do list, and I'm glad to see > someone beat me to it. But you've only done half the job: you > should also be folding operators with constant arguments. > > Also, you need to be wary of functions like now() and random(). > There probably isn't any other way to handle these than to add a > column to pg_proc flagging functions that can't be constant-folded. Already there, pg_proc.proiscachable. -- Bruce Momjian | http://www.op.net/~candle maillist@candle.pha.pa.us | (610) 853-3000+ If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania19026
В списке pgsql-hackers по дате отправления: