Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
dd3099a0
Commit
dd3099a0
authored
Nov 24, 2016
by
Aleksey Midenkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SQL: unsupported engine fix for VTQ funcs
parent
6c516e77
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
3 deletions
+12
-3
sql/item_timefunc.cc
sql/item_timefunc.cc
+9
-0
sql/share/errmsg-utf8.txt
sql/share/errmsg-utf8.txt
+2
-2
sql/sql_select.cc
sql/sql_select.cc
+1
-1
No files found.
sql/item_timefunc.cc
View file @
dd3099a0
...
...
@@ -3322,6 +3322,11 @@ VTQ_common<Item_func_X>::init_hton()
hton
=
plugin_hton
(
plugin_int_to_ref
(
innodb_plugin
));
DBUG_ASSERT
(
hton
);
}
if
(
hton
&&
!
hton
->
versioned
())
{
my_error
(
ER_VERS_ENGINE_UNSUPPORTED
,
MYF
(
0
),
Item
::
name
?
Item
::
name
:
this
->
func_name
());
hton
=
NULL
;
}
}
}
...
...
@@ -3343,6 +3348,7 @@ Item_func_vtq_ts::get_date(MYSQL_TIME *res, ulonglong fuzzy_date)
if
(
!
hton
)
return
true
;
DBUG_ASSERT
(
hton
->
vers_query_trx_id
);
null_value
=
!
hton
->
vers_query_trx_id
(
thd
,
res
,
trx_id
,
vtq_field
);
return
false
;
...
...
@@ -3394,6 +3400,7 @@ Item_func_vtq_id::get_by_trx_id(ulonglong trx_id)
return
0
;
}
DBUG_ASSERT
(
hton
->
vers_query_trx_id
);
null_value
=
!
hton
->
vers_query_trx_id
(
thd
,
&
res
,
trx_id
,
vtq_field
);
return
res
;
}
...
...
@@ -3404,6 +3411,7 @@ Item_func_vtq_id::get_by_commit_ts(MYSQL_TIME &commit_ts, bool backwards)
THD
*
thd
=
current_thd
;
// can it differ from constructor's?
DBUG_ASSERT
(
thd
);
DBUG_ASSERT
(
hton
->
vers_query_commit_ts
);
null_value
=
!
hton
->
vers_query_commit_ts
(
thd
,
&
cached_result
,
commit_ts
,
VTQ_ALL
,
backwards
);
if
(
null_value
)
{
...
...
@@ -3516,6 +3524,7 @@ Item_func_vtq_trx_sees::val_int()
return
true
;
}
DBUG_ASSERT
(
hton
->
vers_trx_sees
);
bool
result
=
false
;
null_value
=
!
hton
->
vers_trx_sees
(
thd
,
result
,
trx_id1
,
trx_id0
,
commit_id1
,
iso_level1
,
commit_id0
);
return
result
;
...
...
sql/share/errmsg-utf8.txt
View file @
dd3099a0
...
...
@@ -7502,8 +7502,8 @@ ER_VERS_FIELD_WRONG_TYPE
ER_VERS_WRONG_PARAMS
eng "Wrong parameters for versioned table %`s: %s"
ER_VERS_
TRX_ID
_UNSUPPORTED
eng "Engine does not support
versioned TRX_ID
"
ER_VERS_
ENGINE
_UNSUPPORTED
eng "Engine does not support
System Versioning for %`s
"
ER_VERS_RANGE_UNITS_MISMATCH
eng "Range units mismatch"
...
...
sql/sql_select.cc
View file @
dd3099a0
...
...
@@ -769,7 +769,7 @@ setup_for_system_time(THD *thd, TABLE_LIST *tables, COND **where_expr, SELECT_LE
{
if
(
slex
->
vers_conditions
.
unit
==
UNIT_TRX_ID
)
{
my_error
(
ER_VERS_
TRX_ID
_UNSUPPORTED
,
MYF
(
0
),
table
->
table_name
);
my_error
(
ER_VERS_
ENGINE
_UNSUPPORTED
,
MYF
(
0
),
table
->
table_name
);
DBUG_RETURN
(
-
1
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment