Someone is updating a record in a custom Oracle table, is there a way to find who is updating the record and or at least the table?
You can audit updates to the table (assuming that auditing is enabled in your database). Or you can create a trigger on the table that captures the user and the row being updated and writes the results to an audit table. Or you can use the
DBMS_LOGMNR package to go through the historical redo logs to see who executed an
UPDATE in the past.
In any of these cases, you'll see the Oracle user that did the
UPDATE. That may or may not be what you want, however. Most applications these days are three-tier applications where the user that is connecting to the database is shared by many different human users. If your middle tier is handling the process of authenticating users and using a single shared Oracle user account in its connection pools, you would need to have the middle tier record who is doing the
UPDATE or you would need for the middle tier to identify to the database who the current application user is for any request via a context, via calls to
DBMS_APPLICATION_INFO, via calls to a stored procedure, or by just passing the user in with the