Is there a way outsde of the profiler to get the sql string with parameter values? like the select __toString() method?
MS -----Original Message----- From: Bill Karwin [mailto:[EMAIL PROTECTED] Sent: Monday, June 09, 2008 12:36 PM To: [email protected] Subject: Re: [fw-general] Zend_Db -> last query with values Mark Steudel-3 wrote: > > I was wondering if it was possible to get back the last run query > including > the values that get swapped in place of the ? > > I tried using the profiler, but it just gives me back the sql statement > before $id gets passed into it. > Zend_Db_Profiler has a function getQueryParams() that returns an array of the values you sent during a given query execution. Zend_Db_Profiler has no function to return the SQL query string with parameter values interpolated into it. That's not how parameters work in SQL. Parameters are separate from the SQL query string; they are never combined with the textual representation of the query. Regards, Bill Karwin -- View this message in context: http://www.nabble.com/Zend_Db--%3E-last-query-with-values-tp17738679p1774008 3.html Sent from the Zend Framework mailing list archive at Nabble.com. No virus found in this incoming message. Checked by AVG. Version: 8.0.100 / Virus Database: 270.1.0/1492 - Release Date: 6/9/2008 10:29 AM
