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
afe2186e
Commit
afe2186e
authored
Nov 19, 2003
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Post-merge fixes.
parent
214ad828
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
66 additions
and
66 deletions
+66
-66
mysql-test/r/query_cache.result
mysql-test/r/query_cache.result
+6
-7
mysql-test/r/sp-error.result
mysql-test/r/sp-error.result
+1
-1
mysql-test/r/sp.result
mysql-test/r/sp.result
+3
-3
mysql-test/t/sp-error.test
mysql-test/t/sp-error.test
+40
-40
mysql-test/t/sp.test
mysql-test/t/sp.test
+3
-3
sql/protocol.cc
sql/protocol.cc
+1
-1
sql/sp_head.cc
sql/sp_head.cc
+1
-0
sql/sql_class.cc
sql/sql_class.cc
+1
-1
sql/sql_delete.cc
sql/sql_delete.cc
+2
-2
sql/sql_parse.cc
sql/sql_parse.cc
+1
-1
sql/sql_select.cc
sql/sql_select.cc
+5
-5
sql/sql_union.cc
sql/sql_union.cc
+1
-1
sql/sql_yacc.yy
sql/sql_yacc.yy
+1
-1
No files found.
mysql-test/r/query_cache.result
View file @
afe2186e
...
@@ -808,17 +808,17 @@ Qcache_hits 6
...
@@ -808,17 +808,17 @@ Qcache_hits 6
show status like "Qcache_queries_in_cache";
show status like "Qcache_queries_in_cache";
Variable_name Value
Variable_name Value
Qcache_queries_in_cache 4
Qcache_queries_in_cache 4
DROP TABLE
t1;
drop table
t1;
create table t1 (a int);
create table t1 (a int);
show status like "Qcache_queries_in_cache";
show status like "Qcache_queries_in_cache";
Variable_name Value
Variable_name Value
Qcache_queries_in_cache 0
Qcache_queries_in_cache 0
show status like "Qcache_inserts";
show status like "Qcache_inserts";
Variable_name Value
Variable_name Value
Qcache_inserts
4
8
Qcache_inserts 8
show status like "Qcache_hits";
show status like "Qcache_hits";
Variable_name Value
Variable_name Value
Qcache_hits
12
Qcache_hits
6
/**/ select * from t1;
/**/ select * from t1;
a
a
/**/ select * from t1;
/**/ select * from t1;
...
@@ -828,10 +828,9 @@ Variable_name Value
...
@@ -828,10 +828,9 @@ Variable_name Value
Qcache_queries_in_cache 1
Qcache_queries_in_cache 1
show status like "Qcache_inserts";
show status like "Qcache_inserts";
Variable_name Value
Variable_name Value
Qcache_inserts
4
9
Qcache_inserts 9
show status like "Qcache_hits";
show status like "Qcache_hits";
Variable_name Value
Variable_name Value
Qcache_hits 13
Qcache_hits 7
drop table t1;
DROP TABLE t1;
SET GLOBAL query_cache_size=0;
SET GLOBAL query_cache_size=0;
mysql-test/r/sp-error.result
View file @
afe2186e
...
@@ -35,7 +35,7 @@ call foo();
...
@@ -35,7 +35,7 @@ call foo();
ERROR HY000: PROCEDURE foo does not exist
ERROR HY000: PROCEDURE foo does not exist
drop procedure if exists foo;
drop procedure if exists foo;
Warnings:
Warnings:
Warning 128
2
PROCEDURE foo does not exist
Warning 128
6
PROCEDURE foo does not exist
create procedure foo()
create procedure foo()
foo: loop
foo: loop
leave bar;
leave bar;
...
...
mysql-test/r/sp.result
View file @
afe2186e
...
@@ -606,7 +606,7 @@ create procedure hndlr4()
...
@@ -606,7 +606,7 @@ create procedure hndlr4()
begin
begin
declare x int default 0;
declare x int default 0;
declare val int; # No default
declare val int; # No default
declare continue handler for 13
06
set x=1;
declare continue handler for 13
10
set x=1;
select data into val from test.t3 where id='z' limit 1; # No hits
select data into val from test.t3 where id='z' limit 1; # No hits
insert into test.t3 values ('z', val);
insert into test.t3 values ('z', val);
end;
end;
...
@@ -619,7 +619,7 @@ drop procedure hndlr4;
...
@@ -619,7 +619,7 @@ drop procedure hndlr4;
create procedure cur1()
create procedure cur1()
begin
begin
declare done int default 0;
declare done int default 0;
declare continue handler for 13
06
set done = 1;
declare continue handler for 13
10
set done = 1;
declare c cursor for select * from test.t2;
declare c cursor for select * from test.t2;
declare a char(16);
declare a char(16);
declare b int;
declare b int;
...
@@ -646,7 +646,7 @@ create table t3 ( s char(16), i int );
...
@@ -646,7 +646,7 @@ create table t3 ( s char(16), i int );
create procedure cur2()
create procedure cur2()
begin
begin
declare done int default 0;
declare done int default 0;
declare continue handler for 13
06
set done = 1;
declare continue handler for 13
10
set done = 1;
declare c1 cursor for select id,data from test.t1;
declare c1 cursor for select id,data from test.t1;
declare c2 cursor for select i from test.t2;
declare c2 cursor for select i from test.t2;
open c1;
open c1;
...
...
mysql-test/t/sp-error.test
View file @
afe2186e
...
@@ -32,18 +32,18 @@ create function func1() returns int
...
@@ -32,18 +32,18 @@ create function func1() returns int
return
42
|
return
42
|
# Can't create recursively
# Can't create recursively
--
error
128
0
--
error
128
4
create
procedure
foo
()
create
procedure
foo
()
create
procedure
bar
()
set
@
x
=
3
|
create
procedure
bar
()
set
@
x
=
3
|
--
error
128
0
--
error
128
4
create
procedure
foo
()
create
procedure
foo
()
create
function
bar
()
returns
double
return
2.3
|
create
function
bar
()
returns
double
return
2.3
|
# Already exists
# Already exists
--
error
128
1
--
error
128
5
create
procedure
proc1
()
create
procedure
proc1
()
set
@
x
=
42
|
set
@
x
=
42
|
--
error
128
1
--
error
128
5
create
function
func1
()
returns
int
create
function
func1
()
returns
int
return
42
|
return
42
|
...
@@ -51,37 +51,37 @@ drop procedure proc1|
...
@@ -51,37 +51,37 @@ drop procedure proc1|
drop
function
func1
|
drop
function
func1
|
# Does not exist
# Does not exist
--
error
128
2
--
error
128
6
alter
procedure
foo
|
alter
procedure
foo
|
--
error
128
2
--
error
128
6
alter
function
foo
|
alter
function
foo
|
--
error
128
2
--
error
128
6
drop
procedure
foo
|
drop
procedure
foo
|
--
error
128
2
--
error
128
6
drop
function
foo
|
drop
function
foo
|
--
error
128
2
--
error
128
6
call
foo
()
|
call
foo
()
|
drop
procedure
if
exists
foo
|
drop
procedure
if
exists
foo
|
# LEAVE/ITERATE with no match
# LEAVE/ITERATE with no match
--
error
128
5
--
error
128
9
create
procedure
foo
()
create
procedure
foo
()
foo
:
loop
foo
:
loop
leave
bar
;
leave
bar
;
end
loop
|
end
loop
|
--
error
128
5
--
error
128
9
create
procedure
foo
()
create
procedure
foo
()
foo
:
loop
foo
:
loop
iterate
bar
;
iterate
bar
;
end
loop
|
end
loop
|
--
error
128
5
--
error
128
9
create
procedure
foo
()
create
procedure
foo
()
foo
:
begin
foo
:
begin
iterate
foo
;
iterate
foo
;
end
|
end
|
# Redefining label
# Redefining label
--
error
12
86
--
error
12
90
create
procedure
foo
()
create
procedure
foo
()
foo
:
loop
foo
:
loop
foo
:
loop
foo
:
loop
...
@@ -90,14 +90,14 @@ foo: loop
...
@@ -90,14 +90,14 @@ foo: loop
end
loop
foo
|
end
loop
foo
|
# End label mismatch
# End label mismatch
--
error
12
87
--
error
12
91
create
procedure
foo
()
create
procedure
foo
()
foo
:
loop
foo
:
loop
set
@
x
=
2
;
set
@
x
=
2
;
end
loop
bar
|
end
loop
bar
|
# Referring to undef variable
# Referring to undef variable
--
error
12
88
--
error
12
92
create
procedure
foo
(
out
x
int
)
create
procedure
foo
(
out
x
int
)
begin
begin
declare
y
int
;
declare
y
int
;
...
@@ -111,17 +111,17 @@ begin
...
@@ -111,17 +111,17 @@ begin
select
name
from
mysql
.
proc
;
select
name
from
mysql
.
proc
;
select
type
from
mysql
.
proc
;
select
type
from
mysql
.
proc
;
end
|
end
|
--
error
12
89
--
error
12
93
call
foo
()
|
call
foo
()
|
drop
procedure
foo
|
drop
procedure
foo
|
# RETURN in FUNCTION only
# RETURN in FUNCTION only
--
error
129
0
--
error
129
4
create
procedure
foo
()
create
procedure
foo
()
return
42
|
return
42
|
# Doesn't allow queries in FUNCTIONs (for now :-( )
# Doesn't allow queries in FUNCTIONs (for now :-( )
--
error
129
1
--
error
129
5
create
function
foo
()
returns
int
create
function
foo
()
returns
int
begin
begin
declare
x
int
;
declare
x
int
;
...
@@ -135,19 +135,19 @@ create procedure p(x int)
...
@@ -135,19 +135,19 @@ create procedure p(x int)
create
function
f
(
x
int
)
returns
int
create
function
f
(
x
int
)
returns
int
return
x
+
42
|
return
x
+
42
|
--
error
129
5
--
error
129
9
call
p
()
|
call
p
()
|
--
error
129
5
--
error
129
9
call
p
(
1
,
2
)
|
call
p
(
1
,
2
)
|
--
error
129
5
--
error
129
9
select
f
()
|
select
f
()
|
--
error
129
5
--
error
129
9
select
f
(
1
,
2
)
|
select
f
(
1
,
2
)
|
drop
procedure
p
|
drop
procedure
p
|
drop
function
f
|
drop
function
f
|
--
error
1
296
--
error
1
300
create
procedure
p
(
val
int
,
out
res
int
)
create
procedure
p
(
val
int
,
out
res
int
)
begin
begin
declare
x
int
default
0
;
declare
x
int
default
0
;
...
@@ -161,7 +161,7 @@ begin
...
@@ -161,7 +161,7 @@ begin
end
if
;
end
if
;
end
|
end
|
--
error
1
296
--
error
1
300
create
procedure
p
(
val
int
,
out
res
int
)
create
procedure
p
(
val
int
,
out
res
int
)
begin
begin
declare
x
int
default
0
;
declare
x
int
default
0
;
...
@@ -176,7 +176,7 @@ begin
...
@@ -176,7 +176,7 @@ begin
end
if
;
end
if
;
end
|
end
|
--
error
1
297
--
error
1
301
create
function
f
(
val
int
)
returns
int
create
function
f
(
val
int
)
returns
int
begin
begin
declare
x
int
;
declare
x
int
;
...
@@ -194,12 +194,12 @@ begin
...
@@ -194,12 +194,12 @@ begin
end
if
;
end
if
;
end
|
end
|
--
error
1
298
--
error
1
302
select
f
(
10
)
|
select
f
(
10
)
|
drop
function
f
|
drop
function
f
|
--
error
1
299
--
error
1
303
create
procedure
p
()
create
procedure
p
()
begin
begin
declare
c
cursor
for
insert
into
test
.
t1
values
(
"foo"
,
42
);
declare
c
cursor
for
insert
into
test
.
t1
values
(
"foo"
,
42
);
...
@@ -208,7 +208,7 @@ begin
...
@@ -208,7 +208,7 @@ begin
close
c
;
close
c
;
end
|
end
|
--
error
130
0
--
error
130
4
create
procedure
p
()
create
procedure
p
()
begin
begin
declare
x
int
;
declare
x
int
;
...
@@ -218,7 +218,7 @@ begin
...
@@ -218,7 +218,7 @@ begin
close
c
;
close
c
;
end
|
end
|
--
error
130
1
--
error
130
5
create
procedure
p
()
create
procedure
p
()
begin
begin
declare
c
cursor
for
select
*
from
test
.
t
;
declare
c
cursor
for
select
*
from
test
.
t
;
...
@@ -240,7 +240,7 @@ begin
...
@@ -240,7 +240,7 @@ begin
open
c
;
open
c
;
close
c
;
close
c
;
end
|
end
|
--
error
130
2
--
error
130
6
call
p
()
|
call
p
()
|
drop
procedure
p
|
drop
procedure
p
|
...
@@ -252,11 +252,11 @@ begin
...
@@ -252,11 +252,11 @@ begin
close
c
;
close
c
;
close
c
;
close
c
;
end
|
end
|
--
error
130
3
--
error
130
7
call
p
()
|
call
p
()
|
drop
procedure
p
|
drop
procedure
p
|
--
error
128
2
--
error
128
6
alter
procedure
bar3
sql
security
invoker
|
alter
procedure
bar3
sql
security
invoker
|
--
error
1059
--
error
1059
alter
procedure
bar3
name
alter
procedure
bar3
name
...
@@ -270,7 +270,7 @@ drop table if exists t1|
...
@@ -270,7 +270,7 @@ drop table if exists t1|
create
table
t1
(
val
int
,
x
float
)
|
create
table
t1
(
val
int
,
x
float
)
|
insert
into
t1
values
(
42
,
3.1
),
(
19
,
1.2
)
|
insert
into
t1
values
(
42
,
3.1
),
(
19
,
1.2
)
|
--
error
130
4
--
error
130
8
create
procedure
p
()
create
procedure
p
()
begin
begin
declare
c
cursor
for
select
*
from
t1
;
declare
c
cursor
for
select
*
from
t1
;
...
@@ -290,7 +290,7 @@ begin
...
@@ -290,7 +290,7 @@ begin
fetch
c
into
x
;
fetch
c
into
x
;
close
c
;
close
c
;
end
|
end
|
--
error
130
5
--
error
130
9
call
p
()
|
call
p
()
|
drop
procedure
p
|
drop
procedure
p
|
...
@@ -305,34 +305,34 @@ begin
...
@@ -305,34 +305,34 @@ begin
fetch
c
into
x
,
y
,
z
;
fetch
c
into
x
,
y
,
z
;
close
c
;
close
c
;
end
|
end
|
--
error
130
5
--
error
130
9
call
p
()
|
call
p
()
|
drop
procedure
p
|
drop
procedure
p
|
--
error
13
07
--
error
13
11
create
procedure
p
(
in
x
int
,
x
char
(
10
))
create
procedure
p
(
in
x
int
,
x
char
(
10
))
begin
begin
end
|
end
|
--
error
13
07
--
error
13
11
create
function
p
(
x
int
,
x
char
(
10
))
create
function
p
(
x
int
,
x
char
(
10
))
begin
begin
end
|
end
|
--
error
13
08
--
error
13
12
create
procedure
p
()
create
procedure
p
()
begin
begin
declare
x
float
;
declare
x
float
;
declare
x
int
;
declare
x
int
;
end
|
end
|
--
error
13
09
--
error
13
13
create
procedure
p
()
create
procedure
p
()
begin
begin
declare
c
condition
for
1064
;
declare
c
condition
for
1064
;
declare
c
condition
for
1065
;
declare
c
condition
for
1065
;
end
|
end
|
--
error
131
0
--
error
131
4
create
procedure
p
()
create
procedure
p
()
begin
begin
declare
c
cursor
for
select
*
from
t1
;
declare
c
cursor
for
select
*
from
t1
;
...
...
mysql-test/t/sp.test
View file @
afe2186e
...
@@ -727,7 +727,7 @@ create procedure hndlr4()
...
@@ -727,7 +727,7 @@ create procedure hndlr4()
begin
begin
declare
x
int
default
0
;
declare
x
int
default
0
;
declare
val
int
;
# No default
declare
val
int
;
# No default
declare
continue
handler
for
13
06
set
x
=
1
;
declare
continue
handler
for
13
10
set
x
=
1
;
select
data
into
val
from
test
.
t3
where
id
=
'z'
limit
1
;
# No hits
select
data
into
val
from
test
.
t3
where
id
=
'z'
limit
1
;
# No hits
...
@@ -746,7 +746,7 @@ drop procedure hndlr4|
...
@@ -746,7 +746,7 @@ drop procedure hndlr4|
create
procedure
cur1
()
create
procedure
cur1
()
begin
begin
declare
done
int
default
0
;
declare
done
int
default
0
;
declare
continue
handler
for
13
06
set
done
=
1
;
declare
continue
handler
for
13
10
set
done
=
1
;
declare
c
cursor
for
select
*
from
test
.
t2
;
declare
c
cursor
for
select
*
from
test
.
t2
;
declare
a
char
(
16
);
declare
a
char
(
16
);
declare
b
int
;
declare
b
int
;
...
@@ -775,7 +775,7 @@ create table t3 ( s char(16), i int )|
...
@@ -775,7 +775,7 @@ create table t3 ( s char(16), i int )|
create
procedure
cur2
()
create
procedure
cur2
()
begin
begin
declare
done
int
default
0
;
declare
done
int
default
0
;
declare
continue
handler
for
13
06
set
done
=
1
;
declare
continue
handler
for
13
10
set
done
=
1
;
declare
c1
cursor
for
select
id
,
data
from
test
.
t1
;
declare
c1
cursor
for
select
id
,
data
from
test
.
t1
;
declare
c2
cursor
for
select
i
from
test
.
t2
;
declare
c2
cursor
for
select
i
from
test
.
t2
;
...
...
sql/protocol.cc
View file @
afe2186e
...
@@ -127,7 +127,7 @@ void send_error(THD *thd, uint sql_errno, const char *err)
...
@@ -127,7 +127,7 @@ void send_error(THD *thd, uint sql_errno, const char *err)
thd
->
net
.
report_error
=
0
;
thd
->
net
.
report_error
=
0
;
/* Abort multi-result sets */
/* Abort multi-result sets */
thd
->
lex
.
found_colon
=
0
;
thd
->
lex
->
found_colon
=
0
;
thd
->
server_status
=
~
SERVER_MORE_RESULTS_EXISTS
;
thd
->
server_status
=
~
SERVER_MORE_RESULTS_EXISTS
;
DBUG_VOID_RETURN
;
DBUG_VOID_RETURN
;
}
}
...
...
sql/sp_head.cc
View file @
afe2186e
...
@@ -454,6 +454,7 @@ sp_head::execute_procedure(THD *thd, List<Item> *args)
...
@@ -454,6 +454,7 @@ sp_head::execute_procedure(THD *thd, List<Item> *args)
suv
=
new
Item_func_set_user_var
(
guv
->
get_name
(),
item
);
suv
=
new
Item_func_set_user_var
(
guv
->
get_name
(),
item
);
suv
->
fix_fields
(
thd
,
NULL
,
&
item
);
suv
->
fix_fields
(
thd
,
NULL
,
&
item
);
suv
->
fix_length_and_dec
();
suv
->
fix_length_and_dec
();
suv
->
check
();
suv
->
update
();
suv
->
update
();
}
}
}
}
...
...
sql/sql_class.cc
View file @
afe2186e
...
@@ -108,7 +108,7 @@ THD::THD():user_time(0), is_fatal_error(0),
...
@@ -108,7 +108,7 @@ THD::THD():user_time(0), is_fatal_error(0),
used_tables
=
0
;
used_tables
=
0
;
cuted_fields
=
sent_row_count
=
current_stmt_id
=
0L
;
cuted_fields
=
sent_row_count
=
current_stmt_id
=
0L
;
// Must be reset to handle error with THD's created for init of mysqld
// Must be reset to handle error with THD's created for init of mysqld
lex
.
current_select
=
0
;
lex
->
current_select
=
0
;
start_time
=
(
time_t
)
0
;
start_time
=
(
time_t
)
0
;
current_linfo
=
0
;
current_linfo
=
0
;
slave_thread
=
0
;
slave_thread
=
0
;
...
...
sql/sql_delete.cc
View file @
afe2186e
...
@@ -66,8 +66,8 @@ int mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds, ORDER *order,
...
@@ -66,8 +66,8 @@ int mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds, ORDER *order,
DBUG_RETURN
(
1
);
DBUG_RETURN
(
1
);
}
}
if
(
thd
->
lex
.
duplicates
==
DUP_IGNORE
)
if
(
thd
->
lex
->
duplicates
==
DUP_IGNORE
)
thd
->
lex
.
select_lex
.
no_error
=
1
;
thd
->
lex
->
select_lex
.
no_error
=
1
;
/* Test if the user wants to delete all rows */
/* Test if the user wants to delete all rows */
if
(
!
using_limit
&&
const_cond
&&
(
!
conds
||
conds
->
val_int
())
&&
if
(
!
using_limit
&&
const_cond
&&
(
!
conds
||
conds
->
val_int
())
&&
...
...
sql/sql_parse.cc
View file @
afe2186e
...
@@ -1876,7 +1876,7 @@ mysql_execute_command(THD *thd)
...
@@ -1876,7 +1876,7 @@ mysql_execute_command(THD *thd)
char
buff
[
1024
];
char
buff
[
1024
];
String
str
(
buff
,(
uint32
)
sizeof
(
buff
),
system_charset_info
);
String
str
(
buff
,(
uint32
)
sizeof
(
buff
),
system_charset_info
);
str
.
length
(
0
);
str
.
length
(
0
);
thd
->
lex
.
unit
.
print
(
&
str
);
thd
->
lex
->
unit
.
print
(
&
str
);
str
.
append
(
'\0'
);
str
.
append
(
'\0'
);
push_warning
(
thd
,
MYSQL_ERROR
::
WARN_LEVEL_NOTE
,
push_warning
(
thd
,
MYSQL_ERROR
::
WARN_LEVEL_NOTE
,
ER_YES
,
str
.
ptr
());
ER_YES
,
str
.
ptr
());
...
...
sql/sql_select.cc
View file @
afe2186e
...
@@ -1586,7 +1586,7 @@ mysql_select(THD *thd, Item ***rref_pointer_array,
...
@@ -1586,7 +1586,7 @@ mysql_select(THD *thd, Item ***rref_pointer_array,
goto
err
;
// 1
goto
err
;
// 1
}
}
if
(
thd
->
lex
.
describe
&
DESCRIBE_EXTENDED
)
if
(
thd
->
lex
->
describe
&
DESCRIBE_EXTENDED
)
{
{
join
->
conds_history
=
join
->
conds
;
join
->
conds_history
=
join
->
conds
;
join
->
having_history
=
(
join
->
having
?
join
->
having
:
join
->
tmp_having
);
join
->
having_history
=
(
join
->
having
?
join
->
having
:
join
->
tmp_having
);
...
@@ -1597,7 +1597,7 @@ mysql_select(THD *thd, Item ***rref_pointer_array,
...
@@ -1597,7 +1597,7 @@ mysql_select(THD *thd, Item ***rref_pointer_array,
join
->
exec
();
join
->
exec
();
if
(
thd
->
lex
.
describe
&
DESCRIBE_EXTENDED
)
if
(
thd
->
lex
->
describe
&
DESCRIBE_EXTENDED
)
{
{
select_lex
->
where
=
join
->
conds_history
;
select_lex
->
where
=
join
->
conds_history
;
select_lex
->
having
=
join
->
having_history
;
select_lex
->
having
=
join
->
having_history
;
...
@@ -9095,8 +9095,8 @@ void st_select_lex::print(THD *thd, String *str)
...
@@ -9095,8 +9095,8 @@ void st_select_lex::print(THD *thd, String *str)
//options
//options
if
(
options
&
SELECT_STRAIGHT_JOIN
)
if
(
options
&
SELECT_STRAIGHT_JOIN
)
str
->
append
(
"straight_join "
,
14
);
str
->
append
(
"straight_join "
,
14
);
if
((
thd
->
lex
.
lock_option
&
TL_READ_HIGH_PRIORITY
)
&&
if
((
thd
->
lex
->
lock_option
&
TL_READ_HIGH_PRIORITY
)
&&
(
this
==
&
thd
->
lex
.
select_lex
))
(
this
==
&
thd
->
lex
->
select_lex
))
str
->
append
(
"high_priority "
,
14
);
str
->
append
(
"high_priority "
,
14
);
if
(
options
&
SELECT_DISTINCT
)
if
(
options
&
SELECT_DISTINCT
)
str
->
append
(
"distinct "
,
9
);
str
->
append
(
"distinct "
,
9
);
...
@@ -9108,7 +9108,7 @@ void st_select_lex::print(THD *thd, String *str)
...
@@ -9108,7 +9108,7 @@ void st_select_lex::print(THD *thd, String *str)
str
->
append
(
"buffer_result "
,
14
);
str
->
append
(
"buffer_result "
,
14
);
if
(
options
&
OPTION_FOUND_ROWS
)
if
(
options
&
OPTION_FOUND_ROWS
)
str
->
append
(
"calc_found_rows "
,
16
);
str
->
append
(
"calc_found_rows "
,
16
);
if
(
!
thd
->
lex
.
safe_to_cache_query
)
if
(
!
thd
->
lex
->
safe_to_cache_query
)
str
->
append
(
"no_cache "
,
9
);
str
->
append
(
"no_cache "
,
9
);
if
(
options
&
OPTION_TO_QUERY_CACHE
)
if
(
options
&
OPTION_TO_QUERY_CACHE
)
str
->
append
(
"cache "
,
6
);
str
->
append
(
"cache "
,
6
);
...
...
sql/sql_union.cc
View file @
afe2186e
...
@@ -382,7 +382,7 @@ int st_select_lex_unit::exec()
...
@@ -382,7 +382,7 @@ int st_select_lex_unit::exec()
select_limit_cnt
=
HA_POS_ERROR
;
// no limit
select_limit_cnt
=
HA_POS_ERROR
;
// no limit
if
(
select_limit_cnt
==
HA_POS_ERROR
)
if
(
select_limit_cnt
==
HA_POS_ERROR
)
options
&=
~
OPTION_FOUND_ROWS
;
options
&=
~
OPTION_FOUND_ROWS
;
else
if
(
found_rows_for_union
&&
!
thd
->
lex
.
describe
)
else
if
(
found_rows_for_union
&&
!
thd
->
lex
->
describe
)
options
|=
OPTION_FOUND_ROWS
;
options
|=
OPTION_FOUND_ROWS
;
fake_select_lex
->
ftfunc_list
=
&
empty_list
;
fake_select_lex
->
ftfunc_list
=
&
empty_list
;
fake_select_lex
->
table_list
.
link_in_list
((
byte
*
)
&
result_table_list
,
fake_select_lex
->
table_list
.
link_in_list
((
byte
*
)
&
result_table_list
,
...
...
sql/sql_yacc.yy
View file @
afe2186e
...
@@ -1776,7 +1776,7 @@ sp_case:
...
@@ -1776,7 +1776,7 @@ sp_case:
else
else
{ /* Simple case: <caseval> = <whenval> */
{ /* Simple case: <caseval> = <whenval> */
Item *var= (Item*) new Item_splocal(ctx->current_framesize()-1);
Item *var= (Item*) new Item_splocal(ctx->current_framesize()-1);
Item *expr=
Item_bool_func2::eq_creator
(var, $1);
Item *expr=
new Item_func_eq
(var, $1);
i= new sp_instr_jump_if_not(ip, expr);
i= new sp_instr_jump_if_not(ip, expr);
}
}
...
...
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