Greg Stark <[EMAIL PROTECTED]> writes:
> Shouldn't Postgres be noticing the non-immutable random() function and not
> making the subquery an InitPlan? 

Perhaps.  In the dim past, using a dummy subquery was the only way to
persuade the planner not to re-evaluate functions that you didn't want
evaluated more than once, so changing this could be expected to break
some existing applications.  Barring some non-invented cases where it
causes problems, I'm inclined to leave it alone.

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
    (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])

Reply via email to