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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
eaaedb69
Commit
eaaedb69
authored
Aug 07, 2004
by
serg@serg.mylan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug#4881 - crash in ALTER .. RENAME if rename fails
parent
dec992d8
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
10 deletions
+8
-10
sql/sql_select.cc
sql/sql_select.cc
+7
-9
sql/sql_table.cc
sql/sql_table.cc
+1
-1
No files found.
sql/sql_select.cc
View file @
eaaedb69
...
@@ -868,9 +868,7 @@ JOIN::optimize()
...
@@ -868,9 +868,7 @@ JOIN::optimize()
((
group_list
&&
const_tables
!=
tables
&&
((
group_list
&&
const_tables
!=
tables
&&
(
!
simple_group
||
(
!
simple_group
||
!
test_if_skip_sort_order
(
&
join_tab
[
const_tables
],
group_list
,
!
test_if_skip_sort_order
(
&
join_tab
[
const_tables
],
group_list
,
unit
->
select_limit_cnt
,
HA_POS_ERROR
,
0
)))
||
select_distinct
)
&&
0
)))
||
select_distinct
)
&&
tmp_table_param
.
quick_group
&&
!
procedure
)
tmp_table_param
.
quick_group
&&
!
procedure
)
{
{
need_tmp
=
1
;
simple_order
=
simple_group
=
0
;
// Force tmp table without sort
need_tmp
=
1
;
simple_order
=
simple_group
=
0
;
// Force tmp table without sort
...
@@ -2320,7 +2318,7 @@ add_key_fields(JOIN_TAB *stat,KEY_FIELD **key_fields,uint *and_level,
...
@@ -2320,7 +2318,7 @@ add_key_fields(JOIN_TAB *stat,KEY_FIELD **key_fields,uint *and_level,
!
(
cond_func
->
used_tables
()
&
OUTER_REF_TABLE_BIT
))
!
(
cond_func
->
used_tables
()
&
OUTER_REF_TABLE_BIT
))
{
{
Item
*
tmp
=
new
Item_null
;
Item
*
tmp
=
new
Item_null
;
if
(
!
tmp
)
// Should never be true
if
(
unlikely
(
!
tmp
))
// Should never be true
return
;
return
;
add_key_field
(
key_fields
,
*
and_level
,
cond_func
,
add_key_field
(
key_fields
,
*
and_level
,
cond_func
,
((
Item_field
*
)
(
cond_func
->
arguments
()[
0
])
->
real_item
())
((
Item_field
*
)
(
cond_func
->
arguments
()[
0
])
->
real_item
())
...
@@ -2731,7 +2729,7 @@ find_best(JOIN *join,table_map rest_tables,uint idx,double record_count,
...
@@ -2731,7 +2729,7 @@ find_best(JOIN *join,table_map rest_tables,uint idx,double record_count,
rec
=
keyuse
->
ref_table_rows
;
rec
=
keyuse
->
ref_table_rows
;
/*
/*
If there is one 'key_column IS NULL' expression, we can
If there is one 'key_column IS NULL' expression, we can
use this ref_or_null optimsation of this field
use this ref_or_null optim
i
sation of this field
*/
*/
found_ref_or_null
|=
(
keyuse
->
optimize
&
found_ref_or_null
|=
(
keyuse
->
optimize
&
KEY_OPTIMIZE_REF_OR_NULL
);
KEY_OPTIMIZE_REF_OR_NULL
);
...
...
sql/sql_table.cc
View file @
eaaedb69
...
@@ -2691,7 +2691,7 @@ int mysql_alter_table(THD *thd,char *new_db, char *new_name,
...
@@ -2691,7 +2691,7 @@ int mysql_alter_table(THD *thd,char *new_db, char *new_name,
if
(
do_send_ok
)
if
(
do_send_ok
)
send_ok
(
thd
);
send_ok
(
thd
);
}
}
else
else
if
(
error
>
0
)
{
{
table
->
file
->
print_error
(
error
,
MYF
(
0
));
table
->
file
->
print_error
(
error
,
MYF
(
0
));
error
=
-
1
;
error
=
-
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