Skip to content

Commit

Permalink
table partition: add test for exchange partition (#37083)
Browse files Browse the repository at this point in the history
close #35996
  • Loading branch information
ymkzpx committed Aug 22, 2022
1 parent 3977a0a commit 2745f1a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ddl/db_partition_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2119,6 +2119,10 @@ func TestAlterTableExchangePartition(t *testing.T) {
tk.MustExec("alter table e18 exchange partition p0 with table e17")
tk.MustQuery("select * /*+ read_from_storage(tiflash[e18]) */ from e18").Check(testkit.Rows("1"))
tk.MustQuery("select * /*+ read_from_storage(tiflash[e17]) */ from e17").Check(testkit.Rows("2"))

tk.MustExec("create table e19 (a int) partition by hash(a) partitions 1")
tk.MustExec("create temporary table e20 (a int)")
tk.MustGetErrCode("alter table e19 exchange partition p0 with table e20", errno.ErrPartitionExchangeTempTable)
}

func TestExchangePartitionTableCompatiable(t *testing.T) {
Expand Down

0 comments on commit 2745f1a

Please sign in to comment.