Application-time periods support (phase 1) (MDEV-16972)

[MDEV-16977] SELECT...AS OF for application periods Created: 2018-08-14  Updated: 2019-03-04  Resolved: 2019-03-04

Status: Closed
Project: MariaDB Server
Component/s: Versioned Tables
Affects Version/s: None
Fix Version/s: 10.4.0

Type: Technical task Priority: Critical
Reporter: Nikita Malyavin Assignee: Nikita Malyavin
Resolution: Won't Fix Votes: 0
Labels: None


 Comments   
Comment by Sergei Golubchik [ 2018-08-14 ]

Note that standard explicitly says that SELECT ... AS OF does not apply to application-period tables

Comment by Nikita Malyavin [ 2018-08-15 ]

The standard says, that they are not sure if this solution is the best, and they look forward for what other researchers would invent.

Worth to metion, that IBM has this extension.

Comment by Nikita Malyavin [ 2019-01-23 ]

Good place to initialize vers_conditions.name is in parser:

> diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc
> index 5f76f36983b..de8ed2f14b3 100644
> --- a/sql/sql_parse.cc
> +++ b/sql/sql_parse.cc
> @@ -8302,6 +8302,7 @@ TABLE_LIST *st_select_lex::add_table_to_list(THD *thd,
>    ptr->ignore_leaves= MY_TEST(table_options & TL_OPTION_IGNORE_LEAVES);
>    ptr->sequence=      MY_TEST(table_options & TL_OPTION_SEQUENCE);
>    ptr->derived=          table->sel;
> +  ptr->vers_conditions.name= "SYSTEM_TIME";

Generated at Thu Feb 08 08:32:59 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.