I have a set of history tables and main tables. I move records from the main table to the history table at regular intervals and export from the history tables.

How do I restore the records back into the main table and not history table?

Thank You