1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-24 19:42:23 +03:00
Commit Graph

46 Commits

Author SHA1 Message Date
9bd3af97df MDEV-15413 Unexpected errors upon CREATE TABLE .. WITH SYSTEM VERSIONING AS SELECT ...
numerous fixes for CREATE ... SELECT with system versioning:
In CREATE ... SELECT the table is created based on the result set,
field properties do not count. That is
* field invisibility is *not* copied over
* AS ROW START/END is *not* copied over
* the history is *not* copied over
* system row_start/row_end fields can *not* be created from the SELECT part
2018-04-10 13:12:36 +02:00
041e9de6f8 wording: don't prohibit 2018-04-10 13:12:36 +02:00
052668f500 simplify versioning tests 2018-02-24 00:50:57 +01:00
558ee2ee84 fix --embedded tests 2018-01-13 02:01:35 +01:00
26971c9aea SQL: versioning info in INFORMATION_SCHEMA
* show SYSTEM VERSIONED in INFORMATION_SCHEMA.TABLES
* show ROW START/ROW END columns in INFORMATION_SCHEMA.COLUMNS
2018-01-10 11:54:21 +03:00
b85efdc3af rename system_time columns
sys_trx_start -> row_start
sys_trx_end -> row_end
2018-01-09 15:49:07 +03:00
ca4dbcff69 Tests: system columns *not* being auto-renamed (create, alter)
it's correct, they preserve their documented names
2018-01-09 14:18:39 +03:00
1a0b986e78 MDEV-14764 Confusing error message: Table t1 must have at least one temporal column
compiler warning (mix of bool and enum in ?:)
2018-01-09 13:56:31 +03:00
b8b5d8d87d MDEV-14828 Server crashes in JOIN::prepare / setup_fields on 2nd execution of PS [fixes #437] 2018-01-02 15:28:50 +03:00
8efca72f4a MDEV-14792 INSERT without column list into table with explicit versioning columns produces bad data 2018-01-01 23:37:02 +03:00
157150cfcf MDEV-14769 Temporary table can be altered into system versioning + system_versioning_alter_history has no effect 2018-01-01 23:37:02 +03:00
9daf583ab6 fix CREATE ... SELECT
move table->vers_update_fields() where it belongs - into fill_record(),
right after table_arg->update_virtual_fields()
2017-12-29 00:23:13 +03:00
1a06a48230 Tests: ER_VERS_DUPLICATE_ROW_START_END check 2017-12-29 00:23:13 +03:00
a04a283469 MDEV-14692 Server crash in MDL_ticket::has_stronger_or_equal_type
SQL: disable system-versioning stuff on TEMPORARY tables
2017-12-21 10:14:25 +03:00
ee68d019d1 SQL: removed VERS_HIDDEN_FLAG [closes #409] 2017-12-19 16:12:56 +03:00
82379ce14d SQL: error messages revised 2017-12-18 19:11:54 +03:00
b55a149194 Timestamp-based versioning for InnoDB [closes #209]
* Removed integer_fields check
* Reworked Vers_parse_info::check_sys_fields()
* Misc renames
* versioned as vers_sys_type_t

* Removed versioned_by_sql(), versioned_by_engine()

versioned() works as before;
versioned(VERS_TIMESTAMP) is versioned_by_sql();
versioned(VERS_TRX_ID) is versioned_by_engine().

* create_tmp_table() fix
* Foreign constraints for timestamp-based
* Range auto-specifier fix
* SQL: 1-row partition rotation fix [fixes #260]
* Fix 'drop system versioning, algorithm=inplace'
2017-12-18 19:03:51 +03:00
27187443ef MDEV-14650 Assertion 0 failed in TABLE::vers_update_fields [fixes #402]
SQL: fixed selecion of handlerton by respecting partitioning
2017-12-14 19:45:11 +03:00
459f40a232 SQL: create..select revisited [closes #370] 2017-12-12 21:30:49 +03:00
03b54a6b8a SQL: table with duplicate ROW START/END columns [fixes #369] 2017-12-08 16:26:17 +03:00
b3fe45bcd4 rephrase error messages, fix quoting 2017-12-08 16:26:17 +03:00
68e160fb25 Tests: removed common.inc from results 2017-12-04 00:49:44 +03:00
5c820a7125 SQL: create_like_table strip versioning for tmp tables [#365 bug 6]
Tests affected (forced versioning):

rpl.rpl_row_merge_engine
2017-12-01 12:21:49 +03:00
7320c683b9 Parser: disable SV for tmp tables [closes #344] 2017-11-27 15:07:33 +03:00
f9b8c908a0 SQL: ADD/DROP SYSTEM VERSIONING syntax for ALTER TABLE 2017-11-17 11:25:49 +03:00
33085349e9 IB, SQL: removed VTQ, added TRT on SQL layer [closes #305] 2017-11-15 00:22:10 +03:00
17bd486f36 SQL: thd_start_utime() fix [fixes #284] 2017-10-17 17:20:46 +03:00
75bc483d7a Tests: moved concat_execN() to common.inc 2017-09-25 22:07:01 +03:00
b4cd2d3c12 Tests: duplicate system versioning field 2017-08-18 15:30:55 +03:00
d3d2ea9fd5 SQL, Parser: system_time logic and syntax fixes [closes #237] 2017-08-08 17:12:16 +03:00
1903b407da SQL: ignore columns WITHOUT VERSIONING [fixes #220] 2017-07-04 17:45:14 +03:00
bdcce58fad IB: long names in information_schema 2017-07-04 12:09:33 +03:00
72de7721b9 SQL: No implicit versioning when created from SELECT [closes #219] 2017-07-03 17:38:59 +03:00
4b0f1284ee SQL: revisit error messages [closes #217] 2017-07-03 14:04:34 +03:00
46d572dde4 SQL: default engine fix in create from versioned [fixes #206] 2017-06-29 12:07:16 +03:00
ec0002e908 Parser: useful attributes for AS ROW fields 2017-05-18 17:46:04 +03:00
b19645caf5 Tests: verify_vtq() fix 2017-05-05 20:36:38 +03:00
67cd92b6f4 SQL, IB: Copy history via CREATE .. SELECT [closes #157, #152] 2017-05-05 20:36:33 +03:00
7a525e7e93 Parser: no implicit NOT NULL for system fields [fixes #163] 2017-05-05 20:36:33 +03:00
9355e3e966 SQL: CREATE TABLE LIKE for versioned tables [fixes #146] 2017-05-05 20:36:29 +03:00
204b54d2d9 SQL: create versioned tmp table from query [fixes #144] 2017-05-05 20:36:28 +03:00
e851c140f4 SQL: (0.5) Versioned partitions [closes #77]
* one `AS OF NOW`, multiple `VERSIONING` partitions;
* rotation of `VERSIONING` partitions by record count, time period;
* rotation is multi-threaded;
* conventional subpartitions as bottom level for versioned partitions;
* `DEFAULT` keyword selects first `VERSIONING` partition;
* ALTER TABLE ADD/DROP partition;
* REBUILD PARTITION basic operation.
2017-05-05 20:36:21 +03:00
a17b8f707f 0.5: basic support for ALTER TABLE for InnoDB and other storage engines [closes #57] 2017-05-05 20:36:21 +03:00
a1c36f2e15 SQL: default NULL for sys fields + misc fixes
* sys fields are NULL by default (with exceptions, see comment about NOT_NULL_FLAG in #77);
* error codes renamed, messages cleared out;
* SHOW CREATE TABLE fixed;
* set_max() fix;
* redundant flag setters/getters removed;
* flags are set in sql_yacc.yy, redundant copy_info_about_generated_fields() eliminated.
2017-05-05 20:36:18 +03:00
303d72a0f4 SQL: redundant error codes reduced
Replaced codes:

ER_NO_VERSIONED_FIELDS_IN_VERSIONED_TABLE
ER_MISSING_WITH_SYSTEM_VERSIONING
ER_SYS_START_NOT_SPECIFIED
ER_SYS_END_NOT_SPECIFIED
ER_MISSING_PERIOD_FOR_SYSTEM_TIME
ER_PERIOD_FOR_SYSTEM_TIME_CONTAINS_WRONG_START_COLUMN
ER_PERIOD_FOR_SYSTEM_TIME_CONTAINS_WRONG_END_COLUMN
ER_SYS_START_AND_SYS_END_SAME
ER_SYS_START_MORE_THAN_ONCE
ER_SYS_END_MORE_THAN_ONCE

with:

ER_VERS_WRONG_PARAMS
ER_VERS_FIELD_WRONG_TYPE
2017-05-05 20:36:18 +03:00
d3b737d910 Tests: moved to dedicated versioning suite
Run `mtr --suite=versioning` or `mtr versioning.<test-name>`
2017-05-05 20:36:13 +03:00