I know you can log queries in Laravel. But I'm wondering if there's a way to also log the name of the script that ran the query. So for instance, if an update query was logged, I'd like to also know that it was initiated by PostController.php.
I'm working on a very large application that uses hundreds of queries, and when I need to remove one, it's very difficult to locate where that query is coming from.
Any ideas?