php - Propel: Get Raw SQL from Query object? -


how raw sql statement query object in propel? need debugging purposes.

for example: have function in

$rawsql = new bookquery::create()->filterbyid(25)->getrawsql(); 

does exist?

yes; you're after tostring method criteria parent class:

$rawsql = (new bookquery)::create()->filterbyid(25)->tostring(); 

as @jakerella says, specific values use filtering bound database engine, rather propel, , you'll see structure of query not executed. if want see that, can check database query logs, if they're enabled.


Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

android - send complex objects as post php java -

charts - What graph/dashboard product is facebook using in Dashboard: PUE & WUE -