Eugene Kosov
f96b1a4e39
MDEV-14798 Add, drop system versioning semantic and syntax
2018-01-12 21:20:23 +01:00
Eugene Kosov
eedab70c1c
MDEV-14871 Server crashes in fill_record / fill_record_n_invoke_before_triggers upon inserting into versioned table with trigger
2018-01-10 12:43:06 +03:00
Sergei Golubchik
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
Sergei Golubchik
6470a9343d
Tests: use bigint in versioning.create,trx_id
2018-01-10 11:53:20 +03:00
Sergei Golubchik
c777add74f
Tests: inserting an explicit value into a vers column
...
must behave as any other generated column: an error in the strict mode,
a warning otherwise.
2018-01-09 15:52:04 +03:00
Sergei Golubchik
b85efdc3af
rename system_time columns
...
sys_trx_start -> row_start
sys_trx_end -> row_end
2018-01-09 15:49:07 +03:00
Sergei Golubchik
be81b00c84
MDEV-14788 System versioning cannot be based on local timestamps, as it is now
...
use system time, not @@timestamp
2018-01-09 15:38:50 +03:00
Sergei Golubchik
d20d7a92c0
make versioning plugin more clearly a test-only thing
...
rename to test_versioning
set maturity to experimental
2018-01-09 15:29:43 +03:00
Sergei Golubchik
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
Sergei Golubchik
35b679b924
SQL: error messages
...
remove unused error messages
reword ER_VERS_SYS_FIELD_NOT_HIDDEN->ER_VERS_SYS_FIELD_EXISTS
2018-01-09 14:16:47 +03:00
Sergei Golubchik
e6a7457653
SQL: derived, hiding, error messages
...
Many related changes.
Note that AS OF condition must always be pushed down to physical tables,
it cannot be applied to a derived or a view. Thus:
* no versioning for internal temporary tables, they can never store
historical data.
* remove special versioning code from mysql_derived_prepare and
remove ER_VERS_DERIVED_PROHIBITED - derived can have no historical
data and cannot be prohibited for system versioning related reasons.
* do not expand select list for derived/views with sys vers fields,
derived/views can never have historical data.
* remove special invisiblity rules for sys vers fields, they are no
longer needed after the previous change
* remove system_versioning_hide, it lost the meaning after the
previous change.
* remove ER_VERS_SYSTEM_TIME_CLASH, it's no "clash", the inner
AS OF clause always wins.
* non-versioned fields in a historical query
reword the warning text, downgrade to note, don't
replace values with NULLs
2018-01-09 14:12:41 +03:00
Sergei Golubchik
b06b5c3eab
Tests: disabled cte.test
...
CTE don't work, report MDEV-14820
2018-01-09 13:57:33 +03:00
Sergei Golubchik
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
Eugene Kosov
5dddbafa4e
MDEV-14821 Assertion !is_set() || (m_status == DA_OK_BULK && is_bulk_op())
failed in Diagnostics_area::set_ok_status
2018-01-08 13:32:02 +03:00
Aleksey Midenkov
912769b7dc
SQL: lower priority of warning in vers_part_rotate() for ALTER [ fixes #446 ]
2018-01-06 11:56:51 +03:00
Eugene Kosov
dbf21ff396
MDEV-14787 CREATE does not allow tables with versioning columns only, but ALTER does
2018-01-03 15:51:23 +03:00
Aleksey Midenkov
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
Aleksey Midenkov
8efca72f4a
MDEV-14792 INSERT without column list into table with explicit versioning columns produces bad data
2018-01-01 23:37:02 +03:00
Eugene Kosov
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
Aleksey Midenkov
7069071d7d
MDEV-14786 Server crashes in Item_cond::transform on 2nd execution of SP querying from a view [ fixes #436 ]
2018-01-01 23:34:39 +03:00
Eugene Kosov
d72462a29b
SQL: TRX_ID to TIMESTAMP versioning switch [ fixes #428 ]
2017-12-29 00:23:20 +03:00
Aleksey Midenkov
d1e4c5d13e
MDEV-14748 Assertion in ha_myisammrg::attach_children() [ fixes #434 ]
2017-12-29 00:23:20 +03:00
Sergei Golubchik
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
Sergei Golubchik
1a06a48230
Tests: ER_VERS_DUPLICATE_ROW_START_END check
2017-12-29 00:23:13 +03:00
Eugene Kosov
0fe67f2ef9
MDEV-14744 Assertion `table->versioned() == m_prebuilt->table->versioned()' failed in ha_innobase::open
2017-12-29 00:23:07 +03:00
Aleksey Midenkov
04451f0f8a
MDEV-14765 Server crashes in Sys_var_vers_asof::update
2017-12-26 15:25:39 +03:00
Aleksey Midenkov
11c6882741
MDEV-14747 ALTER PARTITION BY SYSTEM_TIME after LOCK TABLES
2017-12-26 15:25:39 +03:00
Aleksey Midenkov
4236f589b6
MDEV-14751 Server crashes in TABLE::versioned on 2nd execution of SP [ fixes #431 ]
...
SQL: TABLE_LIST cleanup on free_tmp_table()
May affect non-versioning tests (main suite passed).
2017-12-26 15:25:39 +03:00
Eugene Kosov
d8aabb44b5
SQL: prohibit ALTER ... AS ROW START|END [ fixes #429 ]
2017-12-25 13:38:03 +03:00
Aleksey Midenkov
ea49441c41
Partition: uninitialized vers_info fix
2017-12-22 16:40:09 +03:00
Aleksey Midenkov
57f827cdd6
MDEV-14741 Assertion '(trx)->start_file == 0' failed
...
in row_truncate_table_for_mysql()
2017-12-22 14:52:17 +03:00
Aleksey Midenkov
1e8eae40ce
MDEV-14740 Locking assertion for system_time partitioning
...
Assertion `thd->locked_tables_mode <= LTM_LOCK_TABLES ||
!thd->lex->requires_prelocking()' failed in lock_tables().
2017-12-22 12:51:48 +03:00
Aleksey Midenkov
7e39f70044
MDEV-14722 Partition: assertion in ha_commit_trans() for sub-statement
2017-12-21 16:15:56 +03:00
Aleksey Midenkov
e65a695f28
Tests: disabled embedded for versioning.trx_id [ #387 ]
...
Error ER_VERS_TRT_IS_DISABLED is not thrown.
2017-12-21 15:08:34 +03:00
Eugene Kosov
aa4d1bedfc
MDEV-14689 Server crashes in find_field_in_tables on 2nd execution of PS with versioned table and view
...
SQL: wrong usage of Item::transform()
2017-12-21 14:59:46 +03:00
Eugene Kosov
6dc75b5f89
MDEV-14632 Assertion `!((new_col->prtype ^ col->prtype) & ~256U)' failed in row_log_table_apply_convert_mrec
...
ha_innobase::check_if_supported_inplace_alter(): enabled non-rebuilding operations for trx_id-based system-versioning tables
Also added better error message for not implemented operations.
2017-12-21 14:59:18 +03:00
Aleksey Midenkov
5c760d952b
Parser: default SYSTEM_TIME ALL for DELETE HISTORY
2017-12-21 10:48:48 +03:00
Aleksey Midenkov
36888cc531
MDEV-14686 Server crashes in Item_field::used_tables on 2nd call of SP [ fixes #422 ]
2017-12-21 10:25:32 +03:00
Eugene Kosov
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
Eugene Kosov
acdfacee75
IB: TRT is not updated on ADD SYSTEM VERSIONING [ fixes #413 ]
2017-12-20 22:46:28 +03:00
Eugene Kosov
4bc268d406
MDEV-14632 Assertion `!((new_col->prtype ^ col->prtype) & ~256U)' failed in row_log_table_apply_convert_mrec
...
SQL, IB: proper fix is to disable unimplemented Online DDL for system-versioned tables inside InnoDB
2017-12-20 19:42:15 +03:00
Eugene Kosov
b13f1cc59a
MDEV-14681 Bogus ER_UNSUPPORTED_EXTENSION
2017-12-20 16:41:42 +03:00
Aleksey Midenkov
7eff2080fd
MDEV-14687 DELETE HISTORY in prepared stmt crash [ fixes #421 ]
...
Also fixes broken truncate after 617e108fb6
2017-12-20 16:12:32 +03:00
Aleksey Midenkov
c5d0c38efc
MDEV-14676 Redundancy in error codes
...
ER_VERS_NOT_VERSIONED vs ER_VERSIONING_REQUIRED
2017-12-19 22:05:25 +03:00
Aleksey Midenkov
fc21529f14
MDEV-14683 Possible redundancy in error codes
...
ER_VERS_GENERATED_ALWAYS_NOT_EMPTY vs ER_VERS_ALTER_SYSTEM_FIELD
Related to #310 (91ba4f04be
).
2017-12-19 21:55:40 +03:00
Sergei Golubchik
617e108fb6
s/TRUNCATE ... TO/DELETE HISTORY FROM ... BEFORE/
2017-12-19 16:35:38 +03:00
Aleksey Midenkov
ee68d019d1
SQL: removed VERS_HIDDEN_FLAG [ closes #409 ]
2017-12-19 16:12:56 +03:00
Eugene Kosov
8ba06032ae
MDEV-14684 Assertion `table' failed in mysql_delete
...
SQL: disable TRUNCATE table_name TO statement for VIEWs
2017-12-19 15:12:11 +03:00
Aleksey Midenkov
04bed58acf
SQL: partitioning CREATE, ALTER fixes
...
MDEV-14688 Assertion `tab_part_info->part_type == LIST_PARTITION' failed in prep_alter_part_table
MDEV-14673 Assertion `part_elem->type() == partition_element::AS_OF_NOW' failed in check_partition_info
2017-12-18 22:17:53 +03:00
Aleksey Midenkov
b0d9dc43ca
SQL: system_versioning_transaction_registry default OFF
2017-12-18 22:17:52 +03:00