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
43afb278
Commit
43afb278
authored
Mar 25, 2007
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge olga.mysql.com:/home/igor/mysql-5.0-opt
into olga.mysql.com:/home/igor/dev-opt/mysql-5.0-opt-bug27229
parents
06e38d1d
d95c307f
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
12 deletions
+17
-12
sql/item_sum.cc
sql/item_sum.cc
+1
-2
sql/sql_select.cc
sql/sql_select.cc
+16
-10
No files found.
sql/item_sum.cc
View file @
43afb278
...
...
@@ -449,7 +449,6 @@ void Item_sum::update_used_tables ()
used_tables_cache
&=
PSEUDO_TABLE_BITS
;
/* the aggregate function is aggregated into its local context */
if
(
aggr_level
==
nest_level
)
used_tables_cache
|=
(
1
<<
aggr_sel
->
join
->
tables
)
-
1
;
}
}
...
...
sql/sql_select.cc
View file @
43afb278
...
...
@@ -9196,9 +9196,12 @@ create_tmp_table(THD *thd,TMP_TABLE_PARAM *param,List<Item> &fields,
Item
::
Type
type
=
item
->
type
();
if
(
not_all_columns
)
{
if
(
item
->
with_sum_func
&&
type
!=
Item
::
SUM_FUNC_ITEM
&&
(
type
==
Item
::
SUBSELECT_ITEM
||
(
item
->
used_tables
()
&
~
PSEUDO_TABLE_BITS
)))
if
(
item
->
with_sum_func
&&
type
!=
Item
::
SUM_FUNC_ITEM
)
{
if
(
item
->
used_tables
()
&
OUTER_REF_TABLE_BIT
)
item
->
update_used_tables
();
if
(
type
==
Item
::
SUBSELECT_ITEM
||
(
item
->
used_tables
()
&
~
OUTER_REF_TABLE_BIT
))
{
/*
Mark that the we have ignored an item that refers to a summary
...
...
@@ -9208,6 +9211,7 @@ create_tmp_table(THD *thd,TMP_TABLE_PARAM *param,List<Item> &fields,
param
->
using_indirect_summary_function
=
1
;
continue
;
}
}
if
(
item
->
const_item
()
&&
(
int
)
hidden_field_count
<=
0
)
continue
;
// We don't have to store this
}
...
...
@@ -9391,6 +9395,7 @@ create_tmp_table(THD *thd,TMP_TABLE_PARAM *param,List<Item> &fields,
table
->
s
->
default_values
=
table
->
record
[
1
]
+
alloc_length
;
}
copy_func
[
0
]
=
0
;
// End marker
param
->
func_count
=
copy_func
-
param
->
items_to_copy
;
recinfo
=
param
->
start_recinfo
;
null_flags
=
(
uchar
*
)
table
->
record
[
0
];
...
...
@@ -13571,6 +13576,7 @@ count_field_types(TMP_TABLE_PARAM *param, List<Item> &fields,
if
(
!
sum_item
->
quick_group
)
param
->
quick_group
=
0
;
// UDF SUM function
param
->
sum_func_count
++
;
param
->
func_count
++
;
for
(
uint
i
=
0
;
i
<
sum_item
->
arg_count
;
i
++
)
{
...
...
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