Stan
Stan

Reputation: 21

MySQL Insert date log

I am trying to find out when something was added to a database I maintain but the script that adds the date was working.

Is there a way to retrieve the date of the original INSERT command?

Upvotes: 2

Views: 1251

Answers (2)

ITroubs
ITroubs

Reputation: 11215

make a new table with the key of the table to watch create a after insert trigger that inserts a new line into the watchout table with the id and the time inserted

Upvotes: 1

Slater
Slater

Reputation: 137

Something like this?

http://dev.mysql.com/doc/refman/5.0/en/query-log.html

Upvotes: 1

Related Questions