On Tue, May 25, 2010 at 11:00:02AM +1000, Arjen Lentz wrote:
Hi Sergey
On 25/05/2010, at 6:59 AM, worklog-noreply@askmonty.org wrote:
TASK...........: Push conditions down into non-mergeable VIEWs when possible TASK ID........: 119 (http://askmonty.org/worklog/?tid=119)
Will this have any effect on a VIEW containing a UNION?
This particular task won't, as we're looking to limit the scope of the WL, and UNIONs are an easy target. It is possible to push a condition inside UNION (as long as it's not UNION ... ORDER BY), i.e. (SELECT foo UNION SELECT bar) HAVING x --> (SELECT foo HAVING x) UNION (SELECT bar HAVING h) so we could add support for UNIONs after MWL#119 is complete. Arjen, do you mention UNIONs as something that's technically possible to handle, or you're saying that there are cases with UNIONs of practical importance? BR Sergey -- Sergey Petrunia, Software Developer Monty Program AB, http://askmonty.org Blog: http://s.petrunia.net/blog