Welcome Guest, Not a member yet? Register   Sign In
Profiling Db queries and page load time in a database table

Hi Everyone,

I am new in the Forum and trying out CI4.
While migrating a CI3 projects to CI4, I am stuck at a point.

I want to get all the queries and number of queries from first page load to last, and save it in a table. Obviously, the table will be huge but it was implemented in CI3 by modfying system file.
But now, I do not want to edit the system file of CI4 anymore for this feature.

Can anyone guide me how do I establish the feature for the project in CI4 to save all queries, number of queries (if all queries can be attained, then count of it can also be attained) and the time to load the whole page.

I have gotten an idea to use the Events but I am not totally understood how the process could be done.
An action of flows to how I can implement this wold be appreciated much.

You can take a look at these tutorials and see if they will help you out.

CodeIgniter 4 Complete Events Tutorial

Complete CodeIgniter 4 Model Events Tutorial

Good luck.
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )

Theme © iAndrew 2016 - Forum software by © MyBB