Do you know of any method to show the queries being executed in Lithium as it does in CakePHP. It may become easier for me to find what is executed. At the bottom of the page it shows the queries executed.
![The screen shot] http://imgur.com/ffNfQ
After I received the answer, I added the code to my controller:
Volumes::applyFilter('find', function($self, $params, $chain) {
echo '<pre>===== self ======<br>';
var_dump($self);
echo '===== params ======<br>';
var_dump($params);
echo '===== chain ======<br>';
var_dump($chain);
echo '</pre>';
$next = $chain->next($self, $params, $chain);
return $next;
});
It gives me an output as to all var_dump of self and params, but I require the SQL query which gets executed.
Please check the screen shot http://imgur.com/ffNfQ
Based on all the suggestions by Nils and Mehdi I created a fresh plugin which will only show the query results and not the vardump or print_r() for the queries executed in Lithium with MongoDB.
It really now has become easier for me to find what it being executed.
You can take a look at the project at Github:
https://github.com/nilamdoc/li3_show