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
06d943f1
Commit
06d943f1
authored
Oct 23, 2006
by
kostja@bodhi.local
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Post-merge fixes.
parent
2fecf795
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
168 additions
and
10 deletions
+168
-10
mysql-test/r/sp.result
mysql-test/r/sp.result
+156
-0
mysql-test/r/view.result
mysql-test/r/view.result
+2
-0
server-tools/instance-manager/guardian.cc
server-tools/instance-manager/guardian.cc
+5
-5
server-tools/instance-manager/instance.cc
server-tools/instance-manager/instance.cc
+5
-5
No files found.
mysql-test/r/sp.result
View file @
06d943f1
...
...
@@ -5470,5 +5470,161 @@ CAD
CHF
DROP FUNCTION bug21493|
DROP TABLE t3,t4|
drop function if exists func_20028_a|
drop function if exists func_20028_b|
drop function if exists func_20028_c|
drop procedure if exists proc_20028_a|
drop procedure if exists proc_20028_b|
drop procedure if exists proc_20028_c|
drop table if exists table_20028|
create table table_20028 (i int)|
SET @save_sql_mode=@@sql_mode|
SET sql_mode=''|
create function func_20028_a() returns integer
begin
declare temp integer;
select i into temp from table_20028 limit 1;
return ifnull(temp, 0);
end|
create function func_20028_b() returns integer
begin
return func_20028_a();
end|
create function func_20028_c() returns integer
begin
declare div_zero integer;
set SQL_MODE='TRADITIONAL';
select 1/0 into div_zero;
return div_zero;
end|
create procedure proc_20028_a()
begin
declare temp integer;
select i into temp from table_20028 limit 1;
end|
create procedure proc_20028_b()
begin
call proc_20028_a();
end|
create procedure proc_20028_c()
begin
declare div_zero integer;
set SQL_MODE='TRADITIONAL';
select 1/0 into div_zero;
end|
select func_20028_a()|
func_20028_a()
0
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
select func_20028_b()|
func_20028_b()
0
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
select func_20028_c()|
ERROR 22012: Division by 0
call proc_20028_a()|
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
call proc_20028_b()|
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
call proc_20028_c()|
ERROR 22012: Division by 0
SET sql_mode='TRADITIONAL'|
drop function func_20028_a|
drop function func_20028_b|
drop function func_20028_c|
drop procedure proc_20028_a|
drop procedure proc_20028_b|
drop procedure proc_20028_c|
create function func_20028_a() returns integer
begin
declare temp integer;
select i into temp from table_20028 limit 1;
return ifnull(temp, 0);
end|
create function func_20028_b() returns integer
begin
return func_20028_a();
end|
create function func_20028_c() returns integer
begin
declare div_zero integer;
set SQL_MODE='';
select 1/0 into div_zero;
return div_zero;
end|
create procedure proc_20028_a()
begin
declare temp integer;
select i into temp from table_20028 limit 1;
end|
create procedure proc_20028_b()
begin
call proc_20028_a();
end|
create procedure proc_20028_c()
begin
declare div_zero integer;
set SQL_MODE='';
select 1/0 into div_zero;
end|
select func_20028_a()|
func_20028_a()
0
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
select func_20028_b()|
func_20028_b()
0
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
select func_20028_c()|
func_20028_c()
NULL
call proc_20028_a()|
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
call proc_20028_b()|
Warnings:
Warning 1329 No data - zero rows fetched, selected, or processed
call proc_20028_c()|
SET @@sql_mode=@save_sql_mode|
drop function func_20028_a|
drop function func_20028_b|
drop function func_20028_c|
drop procedure proc_20028_a|
drop procedure proc_20028_b|
drop procedure proc_20028_c|
drop table table_20028|
drop procedure if exists proc_21462_a|
drop procedure if exists proc_21462_b|
create procedure proc_21462_a()
begin
select "Called A";
end|
create procedure proc_21462_b(x int)
begin
select "Called B";
end|
call proc_21462_a|
Called A
Called A
call proc_21462_a()|
Called A
Called A
call proc_21462_a(1)|
ERROR 42000: Incorrect number of arguments for PROCEDURE test.proc_21462_a; expected 0, got 1
call proc_21462_b|
ERROR 42000: Incorrect number of arguments for PROCEDURE test.proc_21462_b; expected 1, got 0
call proc_21462_b()|
ERROR 42000: Incorrect number of arguments for PROCEDURE test.proc_21462_b; expected 1, got 0
call proc_21462_b(1)|
Called B
Called B
drop procedure proc_21462_a|
drop procedure proc_21462_b|
End of 5.0 tests
drop table t1,t2;
mysql-test/r/view.result
View file @
06d943f1
...
...
@@ -2968,6 +2968,8 @@ INSERT INTO t1 VALUES (1);
CREATE FUNCTION f1() RETURNS INT RETURN (SELECT * FROM v1);
UPDATE t1 SET i= f1();
DROP FUNCTION f1;
DROP VIEW v1;
DROP TABLE t1;
CREATE TABLE t1(id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY, val INT UNSIGNED NOT NULL);
CREATE VIEW v1 AS SELECT id, val FROM t1 WHERE val >= 1 AND val <= 5 WITH CHECK OPTION;
INSERT INTO v1 (val) VALUES (2);
...
...
server-tools/instance-manager/guardian.cc
View file @
06d943f1
...
...
@@ -158,7 +158,7 @@ void Guardian_thread::process_instance(Instance *instance,
{
/* clear status fields */
log_info
(
"guardian: instance '%s' is running, set state to STARTED."
,
(
const
char
*
)
instance
->
options
.
instance_name
);
(
const
char
*
)
instance
->
options
.
instance_name
.
str
);
current_node
->
restart_counter
=
0
;
current_node
->
crash_moment
=
0
;
current_node
->
state
=
STARTED
;
...
...
@@ -169,7 +169,7 @@ void Guardian_thread::process_instance(Instance *instance,
switch
(
current_node
->
state
)
{
case
NOT_STARTED
:
log_info
(
"guardian: starting instance '%s'..."
,
(
const
char
*
)
instance
->
options
.
instance_name
);
(
const
char
*
)
instance
->
options
.
instance_name
.
str
);
/* NOTE, set state to STARTING _before_ start() is called */
current_node
->
state
=
STARTING
;
...
...
@@ -194,7 +194,7 @@ void Guardian_thread::process_instance(Instance *instance,
{
instance
->
start
();
log_info
(
"guardian: starting instance '%s'..."
,
(
const
char
*
)
instance
->
options
.
instance_name
);
(
const
char
*
)
instance
->
options
.
instance_name
.
str
);
}
}
else
...
...
@@ -212,13 +212,13 @@ void Guardian_thread::process_instance(Instance *instance,
current_node
->
last_checked
=
current_time
;
current_node
->
restart_counter
++
;
log_info
(
"guardian: restarting instance '%s'..."
,
(
const
char
*
)
instance
->
options
.
instance_name
);
(
const
char
*
)
instance
->
options
.
instance_name
.
str
);
}
}
else
{
log_info
(
"guardian: cannot start instance %s. Abandoning attempts "
"to (re)start it"
,
instance
->
options
.
instance_name
);
"to (re)start it"
,
instance
->
options
.
instance_name
.
str
);
current_node
->
state
=
CRASHED_AND_ABANDONED
;
}
}
...
...
server-tools/instance-manager/instance.cc
View file @
06d943f1
...
...
@@ -166,7 +166,7 @@ static int start_process(Instance_options *instance_options,
exit
(
1
);
case
-
1
:
log_info
(
"cannot create a new process to start instance '%s'."
,
(
const
char
*
)
instance_options
->
instance_name
);
(
const
char
*
)
instance_options
->
instance_name
.
str
);
return
1
;
}
return
0
;
...
...
@@ -312,9 +312,9 @@ void Instance::remove_pid()
int
pid
;
if
((
pid
=
options
.
get_pid
())
!=
0
)
/* check the pidfile */
if
(
options
.
unlink_pidfile
())
/* remove stalled pidfile */
log_error
(
"cannot remove pidfile for instance '%s', this might be
\
since IM lacks permmissions or hasn't found the pidifle"
,
(
const
char
*
)
options
.
instance_name
);
log_error
(
"cannot remove pidfile for instance '%s', this might be
"
"
since IM lacks permmissions or hasn't found the pidifle"
,
(
const
char
*
)
options
.
instance_name
.
str
);
}
...
...
@@ -620,7 +620,7 @@ void Instance::kill_instance(int signum)
log_error
(
"The instance '%s' is being stopped forcibly. Normally"
"it should not happen. Probably the instance has been"
"hanging. You should also check your IM setup"
,
(
const
char
*
)
options
.
instance_name
);
(
const
char
*
)
options
.
instance_name
.
str
);
/* After sucessful hard kill the pidfile need to be removed */
options
.
unlink_pidfile
();
}
...
...
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