As you ask specifically for a RegEx solution, let's start with
) as checked,
That's not the correct syntax for using a cursor. But why even use a cursor when JOIN will do the job much faster. Or a GROUP_CONCAT.
CM.career_id AS id,
CM.name AS career,
AC.name AS area,
GROUP_CONCAT(sd.name FROM specialization_detail
WHERE sd.career_id = row.id)
Why track them?
If it is to see everything that is happening, use the general log.
If it is looking for performance issues, use the slowlog.
Neither the general nor slow logs limit output to specific table(s).
The Audit plugin, if available, is probably better for the former case.
Various "proxy" products could sit between clients and the server; ...
If your interface allows you to get the results in a hash (associative array), then SELECT * should be just fine when you need all the columns.
The other answers point out why SELECT * is likely to bite you in the future. I agree with them.
The Optimizer turns SELECT * into SELECT col1, ... before performing the query, so there is essentially no performance ...
As you need all columns, make a SELECt Col1,col3..... so that is clear that you need all.
In future times, when you view your queries, and you need to figure pit what you have done 5 years ago, it helps to know which columns you select because structures and requirements change, and you must add new columns to the table, you would need more and more ...
There's a third option you forgot to mention, make one DB call, with SELECT COLUMN_LIST. The reason I mention this is because the comparison of when to use SELECT * vs SELECT COLUMN_LIST isn't really about how many database calls one makes, rather it's about schema consistency.
The reason SELECT * is recommended against is because the schema of the dataset ...