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
7b20c33b
Commit
7b20c33b
authored
Aug 24, 2005
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge ibabaev@bk-internal.mysql.com:/home/bk/mysql-5.0
into rurik.mysql.com:/home/igor/mysql-5.0
parents
1432652b
b5c80bdb
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
60 additions
and
43 deletions
+60
-43
configure.in
configure.in
+2
-2
mysql-test/r/sp.result
mysql-test/r/sp.result
+17
-16
mysql-test/t/sp.test
mysql-test/t/sp.test
+17
-16
sql/log_event.cc
sql/log_event.cc
+10
-5
sql/sql_base.cc
sql/sql_base.cc
+14
-4
No files found.
configure.in
View file @
7b20c33b
...
@@ -7,7 +7,7 @@ AC_INIT(sql/mysqld.cc)
...
@@ -7,7 +7,7 @@ AC_INIT(sql/mysqld.cc)
AC_CANONICAL_SYSTEM
AC_CANONICAL_SYSTEM
# The Docs Makefile.am parses this line!
# The Docs Makefile.am parses this line!
# remember to also change ndb version below and update version.c in ndb
# remember to also change ndb version below and update version.c in ndb
AM_INIT_AUTOMAKE
(
mysql, 5.0.1
2
-beta
)
AM_INIT_AUTOMAKE
(
mysql, 5.0.1
3
-beta
)
AM_CONFIG_HEADER
(
config.h
)
AM_CONFIG_HEADER
(
config.h
)
PROTOCOL_VERSION
=
10
PROTOCOL_VERSION
=
10
...
@@ -18,7 +18,7 @@ SHARED_LIB_VERSION=15:0:0
...
@@ -18,7 +18,7 @@ SHARED_LIB_VERSION=15:0:0
# ndb version
# ndb version
NDB_VERSION_MAJOR
=
5
NDB_VERSION_MAJOR
=
5
NDB_VERSION_MINOR
=
0
NDB_VERSION_MINOR
=
0
NDB_VERSION_BUILD
=
1
2
NDB_VERSION_BUILD
=
1
3
NDB_VERSION_STATUS
=
"beta"
NDB_VERSION_STATUS
=
"beta"
# Set all version vars based on $VERSION. How do we do this more elegant ?
# Set all version vars based on $VERSION. How do we do this more elegant ?
...
...
mysql-test/r/sp.result
View file @
7b20c33b
...
@@ -3101,16 +3101,16 @@ call p_bug11247(10)|
...
@@ -3101,16 +3101,16 @@ call p_bug11247(10)|
drop function f_bug11247|
drop function f_bug11247|
drop procedure p_bug11247|
drop procedure p_bug11247|
drop procedure if exists bug12168|
drop procedure if exists bug12168|
drop table if exists t
1, t2
|
drop table if exists t
3, t4
|
create table t
1
(a int)|
create table t
3
(a int)|
insert into t
1
values (1),(2),(3),(4)|
insert into t
3
values (1),(2),(3),(4)|
create table t
2
(a int)|
create table t
4
(a int)|
create procedure bug12168(arg1 char(1))
create procedure bug12168(arg1 char(1))
begin
begin
declare b, c integer;
declare b, c integer;
if arg1 = 'a' then
if arg1 = 'a' then
begin
begin
declare c1 cursor for select a from t
1
where a % 2;
declare c1 cursor for select a from t
3
where a % 2;
declare continue handler for not found set b = 1;
declare continue handler for not found set b = 1;
set b = 0;
set b = 0;
open c1;
open c1;
...
@@ -3119,14 +3119,14 @@ fetch c1 into c;
...
@@ -3119,14 +3119,14 @@ fetch c1 into c;
if (b = 1) then
if (b = 1) then
leave c1_repeat;
leave c1_repeat;
end if;
end if;
insert into t
2
values (c);
insert into t
4
values (c);
until b = 1
until b = 1
end repeat;
end repeat;
end;
end;
end if;
end if;
if arg1 = 'b' then
if arg1 = 'b' then
begin
begin
declare c2 cursor for select a from t
1
where not a % 2;
declare c2 cursor for select a from t
3
where not a % 2;
declare continue handler for not found set b = 1;
declare continue handler for not found set b = 1;
set b = 0;
set b = 0;
open c2;
open c2;
...
@@ -3135,35 +3135,36 @@ fetch c2 into c;
...
@@ -3135,35 +3135,36 @@ fetch c2 into c;
if (b = 1) then
if (b = 1) then
leave c2_repeat;
leave c2_repeat;
end if;
end if;
insert into t
2
values (c);
insert into t
4
values (c);
until b = 1
until b = 1
end repeat;
end repeat;
end;
end;
end if;
end if;
end|
end|
call bug12168('a')|
call bug12168('a')|
select * from t
2
|
select * from t
4
|
a
a
1
1
3
3
truncate t
2
|
truncate t
4
|
call bug12168('b')|
call bug12168('b')|
select * from t
2
|
select * from t
4
|
a
a
2
2
4
4
truncate t
2
|
truncate t
4
|
call bug12168('a')|
call bug12168('a')|
select * from t
2
|
select * from t
4
|
a
a
1
1
3
3
truncate t
2
|
truncate t
4
|
call bug12168('b')|
call bug12168('b')|
select * from t
2
|
select * from t
4
|
a
a
2
2
4
4
truncate t2|
truncate t4|
drop table t3, t4|
drop procedure if exists bug12168|
drop procedure if exists bug12168|
drop table t1,t2;
drop table t1,t2;
mysql-test/t/sp.test
View file @
7b20c33b
...
@@ -3934,20 +3934,20 @@ drop procedure p_bug11247|
...
@@ -3934,20 +3934,20 @@ drop procedure p_bug11247|
#
#
--
disable_warnings
--
disable_warnings
drop
procedure
if
exists
bug12168
|
drop
procedure
if
exists
bug12168
|
drop
table
if
exists
t
1
,
t2
|
drop
table
if
exists
t
3
,
t4
|
--
enable_warnings
--
enable_warnings
create
table
t
1
(
a
int
)
|
create
table
t
3
(
a
int
)
|
insert
into
t
1
values
(
1
),(
2
),(
3
),(
4
)
|
insert
into
t
3
values
(
1
),(
2
),(
3
),(
4
)
|
create
table
t
2
(
a
int
)
|
create
table
t
4
(
a
int
)
|
create
procedure
bug12168
(
arg1
char
(
1
))
create
procedure
bug12168
(
arg1
char
(
1
))
begin
begin
declare
b
,
c
integer
;
declare
b
,
c
integer
;
if
arg1
=
'a'
then
if
arg1
=
'a'
then
begin
begin
declare
c1
cursor
for
select
a
from
t
1
where
a
%
2
;
declare
c1
cursor
for
select
a
from
t
3
where
a
%
2
;
declare
continue
handler
for
not
found
set
b
=
1
;
declare
continue
handler
for
not
found
set
b
=
1
;
set
b
=
0
;
set
b
=
0
;
open
c1
;
open
c1
;
...
@@ -3957,14 +3957,14 @@ begin
...
@@ -3957,14 +3957,14 @@ begin
leave
c1_repeat
;
leave
c1_repeat
;
end
if
;
end
if
;
insert
into
t
2
values
(
c
);
insert
into
t
4
values
(
c
);
until
b
=
1
until
b
=
1
end
repeat
;
end
repeat
;
end
;
end
;
end
if
;
end
if
;
if
arg1
=
'b'
then
if
arg1
=
'b'
then
begin
begin
declare
c2
cursor
for
select
a
from
t
1
where
not
a
%
2
;
declare
c2
cursor
for
select
a
from
t
3
where
not
a
%
2
;
declare
continue
handler
for
not
found
set
b
=
1
;
declare
continue
handler
for
not
found
set
b
=
1
;
set
b
=
0
;
set
b
=
0
;
open
c2
;
open
c2
;
...
@@ -3974,7 +3974,7 @@ begin
...
@@ -3974,7 +3974,7 @@ begin
leave
c2_repeat
;
leave
c2_repeat
;
end
if
;
end
if
;
insert
into
t
2
values
(
c
);
insert
into
t
4
values
(
c
);
until
b
=
1
until
b
=
1
end
repeat
;
end
repeat
;
end
;
end
;
...
@@ -3982,17 +3982,18 @@ begin
...
@@ -3982,17 +3982,18 @@ begin
end
|
end
|
call
bug12168
(
'a'
)
|
call
bug12168
(
'a'
)
|
select
*
from
t
2
|
select
*
from
t
4
|
truncate
t
2
|
truncate
t
4
|
call
bug12168
(
'b'
)
|
call
bug12168
(
'b'
)
|
select
*
from
t
2
|
select
*
from
t
4
|
truncate
t
2
|
truncate
t
4
|
call
bug12168
(
'a'
)
|
call
bug12168
(
'a'
)
|
select
*
from
t
2
|
select
*
from
t
4
|
truncate
t
2
|
truncate
t
4
|
call
bug12168
(
'b'
)
|
call
bug12168
(
'b'
)
|
select
*
from
t2
|
select
*
from
t4
|
truncate
t2
|
truncate
t4
|
drop
table
t3
,
t4
|
drop
procedure
if
exists
bug12168
|
drop
procedure
if
exists
bug12168
|
#
#
...
...
sql/log_event.cc
View file @
7b20c33b
...
@@ -1328,14 +1328,19 @@ Query_log_event::Query_log_event(const char* buf, uint event_len,
...
@@ -1328,14 +1328,19 @@ Query_log_event::Query_log_event(const char* buf, uint event_len,
}
}
}
}
#if !defined(MYSQL_CLIENT) && defined(HAVE_QUERY_CACHE)
if
(
!
(
start
=
data_buf
=
(
char
*
)
my_malloc
(
catalog_len
+
1
+
if
(
!
(
start
=
data_buf
=
(
char
*
)
my_malloc
(
catalog_len
+
1
+
time_zone_len
+
1
+
time_zone_len
+
1
+
data_len
+
1
data_len
+
1
+
#if !defined(MYSQL_CLIENT) && defined(HAVE_QUERY_CACHE)
QUERY_CACHE_FLAGS_SIZE
+
+
QUERY_CACHE_FLAGS_SIZE
+
db_len
+
1
,
db_len
+
1
MYF
(
MY_WME
))))
#else
if
(
!
(
start
=
data_buf
=
(
char
*
)
my_malloc
(
catalog_len
+
1
+
time_zone_len
+
1
+
data_len
+
1
,
MYF
(
MY_WME
))))
#endif
#endif
,
MYF
(
MY_WME
))))
DBUG_VOID_RETURN
;
DBUG_VOID_RETURN
;
if
(
catalog_len
)
// If catalog is given
if
(
catalog_len
)
// If catalog is given
{
{
...
...
sql/sql_base.cc
View file @
7b20c33b
...
@@ -3763,8 +3763,13 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
...
@@ -3763,8 +3763,13 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
TABLE_LIST
*
left_neighbor
,
TABLE_LIST
*
left_neighbor
,
TABLE_LIST
*
right_neighbor
)
TABLE_LIST
*
right_neighbor
)
{
{
Query_arena
*
arena
,
backup
;
bool
result
=
TRUE
;
DBUG_ENTER
(
"store_top_level_join_columns"
);
DBUG_ENTER
(
"store_top_level_join_columns"
);
arena
=
thd
->
change_arena_if_needed
(
&
backup
);
/* Call the procedure recursively for each nested table reference. */
/* Call the procedure recursively for each nested table reference. */
if
(
table_ref
->
nested_join
)
if
(
table_ref
->
nested_join
)
{
{
...
@@ -3797,7 +3802,7 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
...
@@ -3797,7 +3802,7 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
if
(
cur_table_ref
->
nested_join
&&
if
(
cur_table_ref
->
nested_join
&&
store_top_level_join_columns
(
thd
,
cur_table_ref
,
store_top_level_join_columns
(
thd
,
cur_table_ref
,
cur_left_neighbor
,
cur_right_neighbor
))
cur_left_neighbor
,
cur_right_neighbor
))
DBUG_RETURN
(
TRUE
)
;
goto
err
;
cur_right_neighbor
=
cur_table_ref
;
cur_right_neighbor
=
cur_table_ref
;
}
}
}
}
...
@@ -3829,7 +3834,7 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
...
@@ -3829,7 +3834,7 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
swap_variables
(
TABLE_LIST
*
,
table_ref_1
,
table_ref_2
);
swap_variables
(
TABLE_LIST
*
,
table_ref_1
,
table_ref_2
);
if
(
mark_common_columns
(
thd
,
table_ref_1
,
table_ref_2
,
if
(
mark_common_columns
(
thd
,
table_ref_1
,
table_ref_2
,
using_fields
,
&
found_using_fields
))
using_fields
,
&
found_using_fields
))
DBUG_RETURN
(
TRUE
)
;
goto
err
;
/*
/*
Swap the join operands back, so that we pick the columns of the second
Swap the join operands back, so that we pick the columns of the second
...
@@ -3841,7 +3846,7 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
...
@@ -3841,7 +3846,7 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
if
(
store_natural_using_join_columns
(
thd
,
table_ref
,
table_ref_1
,
if
(
store_natural_using_join_columns
(
thd
,
table_ref
,
table_ref_1
,
table_ref_2
,
using_fields
,
table_ref_2
,
using_fields
,
found_using_fields
))
found_using_fields
))
DBUG_RETURN
(
TRUE
)
;
goto
err
;
/*
/*
Change NATURAL JOIN to JOIN ... ON. We do this for both operands
Change NATURAL JOIN to JOIN ... ON. We do this for both operands
...
@@ -3872,7 +3877,12 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
...
@@ -3872,7 +3877,12 @@ store_top_level_join_columns(THD *thd, TABLE_LIST *table_ref,
else
else
table_ref
->
next_name_resolution_table
=
NULL
;
table_ref
->
next_name_resolution_table
=
NULL
;
}
}
DBUG_RETURN
(
FALSE
);
result
=
FALSE
;
/* All is OK. */
err:
if
(
arena
)
thd
->
restore_backup_item_arena
(
arena
,
&
backup
);
DBUG_RETURN
(
result
);
}
}
...
...
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