You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my project i use the log feature to log the SQL calls to check for slow downs etc. if i do something like
$this->f3->get("DB")->exec("
SELECT *
FROM table
WHERE 1
");
(using tabs) it fills the ->log() with lots of new lines and tab characters
(0.9ms) \r\n\t\t\tSELECT DISTINCT tickets.* \r\n\t\t\t\t\r\n\t\t\tFROM tickets \r\n\t\t\t\t\r\n\t\t\tHAVING 1 AND (ID = :'1') \r\n\t\t\t \r\n\t\t\t\r\n\t\t\t;\r\n\t\t\r\n (0.7ms) SELECT * from tickets\r\n
(json_encode the output)
normally this isn't an issue a simple find and replace to clean it up and we're golden. except that if i replace the characters i end up replacing the PHP_EOL between different sql commands
suggestion would be to keep the log in an array rather and maybe to have an output to pure text (in case of cli) or return the array.
as it is now its not that useful for real world "monitoring" of performance etc
The text was updated successfully, but these errors were encountered:
In my project i use the log feature to log the SQL calls to check for slow downs etc. if i do something like
(using tabs) it fills the
->log()
with lots of new lines and tab characters(json_encode the output)
normally this isn't an issue a simple find and replace to clean it up and we're golden. except that if i replace the characters i end up replacing the PHP_EOL between different sql commands
suggestion would be to keep the log in an array rather and maybe to have an output to pure text (in case of cli) or return the array.
as it is now its not that useful for real world "monitoring" of performance etc
The text was updated successfully, but these errors were encountered: