Changing data capture in MySQL

In my database, I want to track the value of a column whenever it changes. So that each time value changes, we can know what the previous value was. It would be great to assign timestamps for each change. I am using MySQL as the database server.

+1
source share
4 answers

To do this, you need to create a trigger, which is an event that fires when it INSERT, UPDATE, DELETEoccurs in this table.

See the documentation for CREATE TRIGGER .

, , , , , INSERT/UPDATE , AFTER , , .

+4

. , , , MySQL. , , , . .

MobiLink iAnywhere. . MobiLink - , MySQL, SQL Anywhere. , - MySQL. , MobiLink , MySQL. , sql-, , - . SQL Anywhere.

, Sybase Central, . , , MobiLink MySQL. , , , , , .

MySQL . , , .

, ...

0

. , , , .

mysql . Mysql API (post version 5.6).

Flexviews, Oracle, Materialized View, .

0

cdc_audit, mysql . ( ETL ). , - .

.

  • .
  • .
  • .csv.
  • Reads mysql information_schema to automatically determine tables and columns.
  • Can generate tables + triggers for all database tables or a specified list.
  • You can synchronize audit tables for all database tables or a specified list.
  • Saves pre-existing trigger logic, if any, when generating AFTER triggers.
  • sync script the ability to delete everything except the last line of the audit to keep the original DB small.
0
source

All Articles