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
39f93cd9
Commit
39f93cd9
authored
May 03, 2006
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rpl_auto_increment_11932.result, rpl_auto_increment_11932.test:
Test case for BUG#11932
parent
3486ba01
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
105 additions
and
0 deletions
+105
-0
mysql-test/r/rpl_auto_increment_11932.result
mysql-test/r/rpl_auto_increment_11932.result
+46
-0
mysql-test/t/rpl_auto_increment_11932.test
mysql-test/t/rpl_auto_increment_11932.test
+59
-0
No files found.
mysql-test/r/rpl_auto_increment_11932.result
0 → 100644
View file @
39f93cd9
stop slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
reset master;
reset slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
start slave;
drop database if exists t1;
create database t1;
use t1;
CREATE TABLE `t` (
`id` int(10) unsigned NOT NULL auto_increment,
`fname` varchar(100) default NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=2 ;
INSERT INTO `t` VALUES (1, 'blablabla');
CREATE TABLE `test3` (
`id` int(10) NOT NULL auto_increment,
`comment` varchar(255) NOT NULL default '',
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=3 ;
INSERT INTO `test3` VALUES (1, 'testtest 1');
INSERT INTO `test3` VALUES (2, 'test 2');
CREATE PROCEDURE simpleproc3 ()
NOT DETERMINISTIC
BEGIN
INSERT INTO t (fname) (SELECT test3.comment FROM test3 WHERE test3.id = '1');
INSERT INTO t (fname) VALUES('test');
END
$
CALL simpleproc3();
select * from test3;
id comment
1 testtest 1
2 test 2
TRUNCATE TABLE `t`;
CALL simpleproc3();
select * from t;
id fname
1 testtest 1
2 test
use t1;
select * from t;
id fname
1 testtest 1
2 test
drop database t1;
mysql-test/t/rpl_auto_increment_11932.test
0 → 100644
View file @
39f93cd9
#
# Test of auto_increment
# BUG#11932
#
# Test supplied by Are Casilla
#
source
include
/
master
-
slave
.
inc
;
--
disable_warnings
connection
master
;
drop
database
if
exists
t1
;
--
enable_warnings
create
database
t1
;
use
t1
;
CREATE
TABLE
`t`
(
`id`
int
(
10
)
unsigned
NOT
NULL
auto_increment
,
`fname`
varchar
(
100
)
default
NULL
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
MyISAM
DEFAULT
CHARSET
=
latin1
AUTO_INCREMENT
=
2
;
INSERT
INTO
`t`
VALUES
(
1
,
'blablabla'
);
CREATE
TABLE
`test3`
(
`id`
int
(
10
)
NOT
NULL
auto_increment
,
`comment`
varchar
(
255
)
NOT
NULL
default
''
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
MyISAM
AUTO_INCREMENT
=
3
;
INSERT
INTO
`test3`
VALUES
(
1
,
'testtest 1'
);
INSERT
INTO
`test3`
VALUES
(
2
,
'test 2'
);
DELIMITER
$
;
CREATE
PROCEDURE
simpleproc3
()
NOT
DETERMINISTIC
BEGIN
INSERT
INTO
t
(
fname
)
(
SELECT
test3
.
comment
FROM
test3
WHERE
test3
.
id
=
'1'
);
INSERT
INTO
t
(
fname
)
VALUES
(
'test'
);
END
$
DELIMITER
;
$
CALL
simpleproc3
();
select
*
from
test3
;
TRUNCATE
TABLE
`t`
;
CALL
simpleproc3
();
select
*
from
t
;
save_master_pos
;
connection
slave
;
sync_with_master
;
use
t1
;
select
*
from
t
;
drop
database
t1
;
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