I'm working on a project based on Cake PHP.On that project recursive = 2 is used and that makes the application slow. Now I need To Optimize Some Query for slow response. For optimizing Query I can Follow two steps:
My Question is When I Should use Containable Behavior and when unbinding Models.I Think I need Some Clear Explanation From Cake PHP Expert.
Those are just some of the quickest ways to optimizes your queries. There are also ways to optimize queries using bindModel for certain requests, or restructuring your tables in certain ways, but those are very situation-specific.