Using phpactiverecord from http://www.phpactiverecord.org/, is there any way to see the generated SQL query for debugging, other than viewing the database server's query log?
Within your Model:
echo self::connection()->last_query;
Outside your Model:
YourModelName::connection()->last_query;