Author Topic: MySQL Database Audit Table?  (Read 567 times)

0 Members and 1 Guest are viewing this topic.

Offline random1Topic starter

  • Enthusiast
  • Posts: 408
    • View Profile
MySQL Database Audit Table?
« on: March 04, 2010, 12:28:43 AM »
Hi All,

Does MySQL have an automatic auditing functionality?

i.e. Do I have to create an audit table that stores the date and time a record/field was last updated?

OR does Mysql have a way of asking it "When was record '1' in table 'a' last updated (edited)?

e.g. maybe something like "SELECT LAST UPDATED table_name(1);" ?

The datetime format im using is UTC.

Online fenway

  • MySQL Si-Fu / PHP Resident Alien
  • Global Moderator
  • 'Mind Boggling!'
  • *
  • Posts: 15,443
  • Gender: Male
    • View Profile
Re: MySQL Database Audit Table?
« Reply #1 on: March 04, 2010, 09:58:16 AM »
Nope -- add a "modified" column, and use magical timestamp or insert it yourself (the latter is preferable).
:anim_rules: Seriously... if people don't start reading this before posting, I'm going to consider not answering at all.