ZF-2856: Add method for UNION


It would be nice if a UNION method was eventually added to Zend_Db_Select. If I get a bit (ha, that'll happen), I'll try to write a patch for it if nobody gets to it first.


Maybe a method of Zend_Db_Adapter?

$sql = $db->union(array($sel1, $sel2, $sel3));

I write $sql because it wouldn't be a Zend_Db_Select instance... i.e. I can't call a where() after the union...

Please categorize/fix as needed.

Actually, I do think this belongs to the Zend_Db_Select as it is part of constructing a query and you can also manipulate the 'having', 'order' and 'limit' clauses.

I'm testing a prototype now and will release to the incubator when the unit tests have been written.

Resolved in r9170 - documentation to be updated shortly

Updating for the 1.6.0 release.