Tuesday, December 2, 2008

Model based on a database query/view

I have a complex database view that includes a large amount of joins
(6) and aggregation functions (eg. SUM). I know this already breaks
the MVC pattern, but I can't even imagine how it could be efficiently
implemented using Model relationships.

I have successfully implemented a read-only page of the database view
using the "QUERY" function. However, I am unable to use the Paginate
functionality with this approach.

Is it valid to create a Model of the database view? What issues are
associated with this approach?

Thanks for any feedback in advance.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: