HomeMogDBMogDB StackUqbar

Documentation:v2.0

Supported Versions:

MTK Parameter

Parameter

noSupportPartTabToNormalTab

Type: bool

Desc: Convert the partition table not supported by the target end to a normal table, and automatically remove the sub-partition table attributes not supported by the target end. Supported methods for checking the partition table

  1. Whether the partition type support
  2. Whether the subpartition type support
  3. Whether the interval type support
  4. Whether the partition key contains virtual columns support

ignoreDB2PartInclusive

Type: bool

Desc: Indicates whether to ignore the INCLUSIVE property of the key value ENDING in the DB2 partition.

For example, in the table creation syntax of the DB2 partition, if ENDING contains the definition of the INCLUSIVE property, the DB2 partition will contain 20180101.

However, the openGauss range partitions do not support the INCLUSIVE but only less than property. In this case, the error the part DATAMIN is included high value for db2 inclusive option will occur. You can ignore the error by configuring the ignoreDB2PartInclusive parameter.

CREATE TABLE MTK1.TABLE_TEST_HAOTD
(
    DATADATE VARCHAR(8) NOT NULL,
    DATA1    VARCHAR(10),
    DATA2    VARCHAR(10)
) PARTITION BY RANGE(DATADATE) (
  PART "DATAMIN" STARTING(MINVALUE) ENDING('20180101') INCLUSIVE ,
  PART "P20180101" STARTING('20180101') ENDING('20180102') INCLUSIVE
)

Default: false

igNotSupportIntervalPart

Type: bool

Desc: Supports ignoring of some unsupported interval partition properties.

Default: false

ignoreTabPartition

Type: bool

Desc: Supports migration to the target database and ignoring of partition syntax.

For example, if the Oracle partition table is migrated to MySQL, it becomes a non-partition table

Oracle

CREATE TABLE "MTK"."TAB_PART_LIST" (
  "DEPTNO" NUMBER(10,0) NOT NULL,
  "DEPTNAME" VARCHAR2(20 BYTE),
  "QUARTERLY_SALES" NUMBER(10,2),
  "STATE" VARCHAR2(2 BYTE)
) PARTITION BY LIST ("STATE")
(
  PARTITION "Q1_NORTHWEST" VALUES ('OR', 'WA') TABLESPACE "USERS",
  PARTITION "Q1_SOUTHWEST" VALUES ('AZ', 'CA', 'NM') TABLESPACE "USERS",
  PARTITION "Q1_NORTHEAST" VALUES ('NY', 'VT', 'NJ') TABLESPACE "USERS",
  PARTITION "Q1_SOUTHEAST" VALUES ('FL', 'GA') TABLESPACE "USERS",
  PARTITION "Q1_NORTHCENT" VALUES ('MN', 'WI') TABLESPACE "USERS",
  PARTITION "Q1_SOUTHCENT" VALUES ('OK', 'TX') TABLESPACE "USERS"
)

MySQL

CREATE TABLE mtk.tab_part_list (
  deptno BIGINT NOT NULL,
  deptname VARCHAR(20),
  quarterly_sales DECIMAL(10,2),
  state VARCHAR(2)
)

Default: false

ignoreTabPartitionTabList

Type: []string

Desc: ignoreTabPartition whitelist

Parameters are case-sensitive

  • "Schema1.TABLE_1" is the table of TABLE_1 under Schema1 in the migration object
  • "Schema1.TABLE*" table of TABLE* under Schema1 in the migration object

Default: null

Example:

ignore Table Partition Table List Example

{
  "ignoreTabPartitionTabList": [
    "SCHEMA1.TABLE_1",
    "SCHEMA1.TABLE_DUTY_LOG*",
    "SCHEMA1.^TABLE_DUTY_LOG.*$"
  ]
}

Add: v2.8.0

autoAddMaxvaluePart

Type: bool

Desc: allows to automatically add a maxvalue partition to a partition table where no maxvalue partition exists.

For example, DB2 partitioned tables are migrated to openGauss.

DB2 allows defining minvalue partitions, which openGauss does not support.

When DB2 defines the minvalue partition without defining the maxvalue partition, the null value can be inserted into the minvalue partition, and openGauss will report an error.

But openGauss allows null value to be inserted into the maxvalue partition. This parameter can be used to enable automatic addition of maxvalue partitions.

DB2 does not define the maxvalue partition.

CREATE TABLE MTK1.PART_TAB_TEST02 (
 ID INTEGER NOT NULL,
 SALES_PERSON VARCHAR(50),
 REGION VARCHAR(50),
 SALES_DATE DATE
)
PARTITION BY RANGE(SALES_DATE)
(
 PART PJAN STARTING('2017-01-01') ENDING('2017-03-31') INCLUSIVE IN USERSPACE1,
 PART PFEB STARTING('2017-04-01') ENDING('2017-07-31') INCLUSIVE IN USERSPACE1,
 PART PMAR STARTING('2017-08-01') ENDING('2017-12-31') INCLUSIVE IN USERSPACE1,
 PART PAPR STARTING('2018-01-01') ENDING('2018-12-31') INCLUSIVE IN USERSPACE1
) ORGANIZE BY ROW

openGauss

CREATE TABLE DB2_MTK.PART_TAB_TEST02 (
 ID INTEGER NOT NULL,
 SALES_PERSON VARCHAR(50),
 REGION VARCHAR(50),
 SALES_DATE DATE
) PARTITION BY RANGE (SALES_DATE)
(
    PARTITION PJAN VALUES LESS THAN('2017-03-31'),
    PARTITION PFEB VALUES LESS THAN('2017-07-31'),
    PARTITION PMAR VALUES LESS THAN('2017-12-31'),
    PARTITION PAPR VALUES LESS THAN('2018-12-31'),
    PARTITION PART_MAXVALUE VALUES LESS THAN(MAXVALUE)
)

Add: v0.0.36

Copyright © 2011-2024 www.enmotech.com All rights reserved.