User-1634604574 posted
I have 2 tables, Table-A
and Table-A-History
.
Table-A
contains current data rows. Table-A-History
contains historical data
I would like to have the most current row of my data in Table-A
, and Table-A-History
containing historical rows.
I can think of 2 ways to accomplish this:
-
whenever a new data row is available, move the current row from Table-A
to Table-A-History
and update the Table-A
row
with the latest data (via insert into select
or select into table
)
i want to use one trigger for all tables in db if any table inserted new row save that new row in
Table-A-History
any delete happened also save it in Table-A-History
and any record updated which column updated save it in Table-A-History