I need to add query logging in Symfony and in csv file. Sometime database can be busy or not available but I want to log all queries.
This log should be in csv format with columns:
-url
-datasource name
-SQL content
-parameters
-username
-start time of query execution (accuracy in ms)
-end time of query execution (accuracy in ms)
Is any help how can I do this? or what can be done for this?
Maybe Custom Function In which I can create the csv file with the current login user info with the url and time to execute the query to access that particular url?