I have a site in laravel where a single page makes multiple database queries (select statements which can take a little while to run).
Is there a way to detect if a user:
- Refreshes the page
- Changes the parameters of the query
- Closes the page
hence meaning that the result of the query is not needed, and therefore cancelling it or killing the process?
Note the database is mysql so I can from mysql workbench easily call kill {PID}
to end a similar query manually.
Thanks!