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
85971707
Commit
85971707
authored
May 21, 2014
by
Nirbhay Choubey
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added test for MDEV#4953.
parent
2f90221a
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
54 additions
and
17 deletions
+54
-17
mysql-test/suite/galera/r/partition.result
mysql-test/suite/galera/r/partition.result
+23
-0
mysql-test/suite/galera/t/partition.test
mysql-test/suite/galera/t/partition.test
+31
-0
sql/ha_partition.h
sql/ha_partition.h
+0
-9
sql/table.cc
sql/table.cc
+0
-8
No files found.
mysql-test/suite/galera/r/partition.result
0 → 100644
View file @
85971707
#
# MDEV#4953 Galera: DELETE from a partitioned table is not replicated
#
USE test;
CREATE TABLE t1 (pk INT PRIMARY KEY, i INT) ENGINE=INNODB PARTITION BY HASH(pk) PARTITIONS 2;
INSERT INTO t1 VALUES (1,100), (2,200);
SELECT * FROM t1;
pk i
2 200
1 100
DELETE FROM t1;
SELECT * FROM t1;
pk i
# On node_1
SELECT * FROM t1;
pk i
# On node_2
SELECT * FROM t1;
pk i
DROP TABLE t1;
# End of test
mysql-test/suite/galera/t/partition.test
0 → 100644
View file @
85971707
--
source
include
/
galera_cluster
.
inc
--
source
include
/
have_innodb
.
inc
--
source
include
/
have_partition
.
inc
--
echo
#
--
echo
# MDEV#4953 Galera: DELETE from a partitioned table is not replicated
--
echo
#
USE
test
;
CREATE
TABLE
t1
(
pk
INT
PRIMARY
KEY
,
i
INT
)
ENGINE
=
INNODB
PARTITION
BY
HASH
(
pk
)
PARTITIONS
2
;
INSERT
INTO
t1
VALUES
(
1
,
100
),
(
2
,
200
);
SELECT
*
FROM
t1
;
DELETE
FROM
t1
;
SELECT
*
FROM
t1
;
--
echo
--
echo
# On node_1
--
connection
node_1
SELECT
*
FROM
t1
;
--
echo
--
echo
# On node_2
--
connection
node_2
SELECT
*
FROM
t1
;
# Cleanup
DROP
TABLE
t1
;
--
source
include
/
galera_end
.
inc
--
echo
# End of test
sql/ha_partition.h
View file @
85971707
...
@@ -1284,17 +1284,8 @@ public:
...
@@ -1284,17 +1284,8 @@ public:
}
}
#ifdef WITH_WSREP
#ifdef WITH_WSREP
virtual
int
wsrep_db_type
()
const
;
virtual
int
wsrep_db_type
()
const
;
#if 0
// TODO: Verify : https://mariadb.atlassian.net/browse/MDEV-4953
void wsrep_reset_files()
{
for (uint i=0; i < m_tot_parts; i++)
m_file[i]->ha_start_of_new_statement();
}
#endif
#endif
/* WITH_WSREP */
#endif
/* WITH_WSREP */
friend
int
cmp_key_rowid_part_id
(
void
*
ptr
,
uchar
*
ref1
,
uchar
*
ref2
);
friend
int
cmp_key_rowid_part_id
(
void
*
ptr
,
uchar
*
ref1
,
uchar
*
ref2
);
};
};
...
...
sql/table.cc
View file @
85971707
...
@@ -4019,14 +4019,6 @@ void TABLE::init(THD *thd, TABLE_LIST *tl)
...
@@ -4019,14 +4019,6 @@ void TABLE::init(THD *thd, TABLE_LIST *tl)
insert_values
=
0
;
insert_values
=
0
;
fulltext_searched
=
0
;
fulltext_searched
=
0
;
file
->
ft_handler
=
0
;
file
->
ft_handler
=
0
;
#if 0
#ifdef WITH_WSREP
if (file->ht->db_type == DB_TYPE_PARTITION_DB)
{
((ha_partition*)file)->wsrep_reset_files();
}
#endif
#endif
reginfo
.
impossible_range
=
0
;
reginfo
.
impossible_range
=
0
;
created
=
TRUE
;
created
=
TRUE
;
cond_selectivity
=
1.0
;
cond_selectivity
=
1.0
;
...
...
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