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
4f410473
Commit
4f410473
authored
Mar 17, 2019
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
post-merge: --ps-protocol fixes
parent
f38c3521
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
7 deletions
+11
-7
mysql-test/main/view.test
mysql-test/main/view.test
+4
-0
sql/sql_tvc.cc
sql/sql_tvc.cc
+7
-7
No files found.
mysql-test/main/view.test
View file @
4f410473
...
...
@@ -2054,7 +2054,9 @@ flush status;
create
table
t1
(
f1
char
(
1
));
create
view
v1
as
select
*
from
t1
;
select
*
from
(
select
f1
as
f2
,
f1
as
f3
from
v1
)
v
where
v
.
f2
=
'a'
;
--
disable_ps_protocol
show
status
like
"Created_tmp%"
;
--
enable_ps_protocol
drop
view
v1
;
drop
table
t1
;
...
...
@@ -2063,7 +2065,9 @@ set @@optimizer_switch='derived_merge=OFF';
create
table
t1
(
f1
char
(
1
));
create
view
v1
as
select
*
from
t1
;
select
*
from
(
select
f1
as
f2
,
f1
as
f3
from
v1
)
v
where
v
.
f2
=
'a'
;
--
disable_ps_protocol
show
status
like
"Created_tmp%"
;
--
enable_ps_protocol
drop
view
v1
;
drop
table
t1
;
set
@@
optimizer_switch
=@
tmp
;
...
...
sql/sql_tvc.cc
View file @
4f410473
...
...
@@ -230,30 +230,30 @@ bool table_value_constr::prepare(THD *thd, SELECT_LEX *sl,
if
(
fix_fields_for_tvc
(
thd
,
li
))
DBUG_RETURN
(
true
);
if
(
!
(
holders
=
new
(
thd
->
mem_root
)
Type_holder
[
cnt
])
||
join_type_handlers_for_tvc
(
thd
,
li
,
holders
,
cnt
)
||
if
(
!
(
holders
=
new
(
thd
->
stmt_arena
->
mem_root
)
Type_holder
[
cnt
])
||
join_type_handlers_for_tvc
(
thd
,
li
,
holders
,
cnt
)
||
get_type_attributes_for_tvc
(
thd
,
li
,
holders
,
lists_of_values
.
elements
,
cnt
))
DBUG_RETURN
(
true
);
List_iterator_fast
<
Item
>
it
(
*
first_elem
);
Item
*
item
;
Query_arena
*
arena
,
backup
;
arena
=
thd
->
activate_stmt_arena_if_needed
(
&
backup
);
sl
->
item_list
.
empty
();
for
(
uint
pos
=
0
;
(
item
=
it
++
);
pos
++
)
{
/* Error's in 'new' will be detected after loop */
Item_type_holder
*
new_holder
=
new
(
thd
->
mem_root
)
Item_type_holder
(
thd
,
item
,
holders
[
pos
].
type_handler
(),
Item_type_holder
(
thd
,
item
,
holders
[
pos
].
type_handler
(),
&
holders
[
pos
]
/*Type_all_attributes*/
,
holders
[
pos
].
get_maybe_null
());
new_holder
->
fix_fields
(
thd
,
0
);
sl
->
item_list
.
push_back
(
new_holder
);
}
if
(
arena
)
thd
->
restore_active_arena
(
arena
,
&
backup
);
if
(
unlikely
(
thd
->
is_fatal_error
))
DBUG_RETURN
(
true
);
// out of memory
...
...
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