March 30, 2021 at 12:50 am
We always use template SQL scripts to create tables, and for temporal tables, the HISTORY_TABLE clause is there.
CREATE TABLE dbo.TheTableName
...
( SYSTEM_VERSIONING = ON ( HISTORY_TABLE = dbo.TheTableName_hst )
...;
We do a "replace all" on TheTableName, and we get proper history table management.
I was excited when I first heard about temporal tables support. I was disappointed to find out is was only transaction-time support without valid-time support. None the less, we used to do a lot of archive tables, where the main table has an UPDATE, DELETE trigger that writes the "deleted" data to an archive table. For us, we just use temporal tables as a quick to implement solution for that. I don't think we ever actually use queries that include the temporal FOR clause (e.g., FOR SYSTEM_TIME BETWEEN '2015-01-01' AND '2015-12-31').
Sincerely,
Daniel
April 5, 2021 at 12:00 am
Comments posted to this topic are about the item System-Versioned Temporal Tables - A Case Study
December 15, 2021 at 7:09 am
This was removed by the editor as SPAM
December 15, 2021 at 7:11 am
This was removed by the editor as SPAM
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply