标签: sql propel
如何使用propel这种语句获取sql查询?
$books = BookQuery::create() ->filterByTitle('War And Peace') ->find();
我需要记录查询以进行调试
query ['SELECT book.* from `book` WHERE book.TITLE = War And Peace' ]
答案 0 :(得分:2)
您可以使用$books->toString()方法。
$books->toString()