Is there a way to enable an audit trail for DB changes? That is, I want to know when a db record was changed and who was the user who changed it. I know about enabling “ON UPDATE CURRENT_TIMESTAMP” but that doesn’t tell me who the user was.
Not automatically. You’d have to code your application to keep track of that.
When you are logging user activities, please keep your table as simple as you can. Please make sure it will be fast to insert a record into the table otherwise it will be an overhead to your application.