©SQL :: Manager
HomeProgram InformationTechnical detailsFree downloadDonate for a cup of coffee
myway SQL Manager for MySQL and MariaDB, Download on Uptodown
Create system-versioned tables in MariaDB

Creating system-versioned tables in MariaDB databases

Create MySQL table This module is part of the table administration
Create system versioned table
System-versioned tables are provided by MariaDB from version 10.3.
A third window then appears in the table header with the selection of the table type and the ROW START and ROW END fields, which have no function when creating a new table.


With newer database versions, the period fields ROW START and ROW END can also be omitted.
Allowed types for these fields are BIGINT and TIMESTAMP. With older database versions, selecting TIMESTAMP generates an error message about an incorrect default value.
The program makes the correct settings for the data types automatically: BIGINT(20) UNSIGNED and TIMSTAMP(6).
Table creation as SQL script View and run table creation as SQL script
Create table Create the new table in the database
Table header:
Name: Name of the new table
Comment: Comment to be stored for the new table.
Next autoindex: First AUTO_INCREMENT value for new table.

Engine: Database format of the new table.
Collation: Character set and collation of the new table.
Row format: Format in which the table rows should be managed in the database.

Table type: Selection of the table type. (BASE TABLE, SYSTEM VERSIONED)
Period start column: Period column ROW START for SYSTEM VERSIONED. No function for new creation.
Period end column: Period column ROW END for SYSTEM VERSIONED. No function for new creation.
 
Table columns:
Name: Column name
SV: Select whether an update to the field creates a history data line at SYSTEM VERSIONED.
P/S: A primary or spatial index is to be created from a field.
U: A unique index is to be created from field.
I: A simple index is to be created from field.
F: A simple full-text index is to be created from field.
Type: Data type of the field.
Length/value: Storage size or format of the data type.
Default value: Default value of the data type.
Character strings must be set in quotation marks.
MariaDB also allows functions here.
NULL: Field accepts NULL values.
Option: Data type options.
Collation: Collation assignment for character string data types.
Extra: Extra options for data field (AUTO_INCREMENT, ON UPDATE CURRENT_TIMESTAMP).
For system-versioned tables, ROW START and ROW END are used here for the period fields set.
Comment: Comment to be stored for the data field.
 
Table options:
Create fields after: Number of new columns to be created from the specified position.
Data directory target table: Path to the directory on the server where the data files are to be saved.
Index directory target table: Path to the directory on the server in which the index files are to be stored (MyISAM only).
Add data column Add data column after this position.
Remove data column Remove data column from table builder.
Table after creating:
System-versioned table after creating
See also: Partitioning of system-versioned tables
More information about system versioned tables can be found here:
mariadb.com
More information on creating MySQL tables can be found here: mysql.com and mariadb.com
Updated: 2023-09-15ImprintContactTerms & conditionsPrivacy & CookiesUpdatesSitemapFacebookLinkedinTwitterStatistics©2020-2024 Heino Cunze-Fischer