hi,
Anyone knows a good way to make UNION query in CakePHP? I would like
to avoid using $this->query();.
for this code =>
"Select distinct bm.id,name, add
From table1 bm,
(Select id bid, count(id) cnt
from table2
where status = 'N'
group by id
union all
Select id bid, count(id) cnt
from table3
where status = 'N'
group by id
order by cnt
limit 10) ab Where id =
bm.id"
--
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others
with their CakePHP related questions.
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at
http://groups.google.com/group/cake-php