The following tables map OpenSearch Retrieval Engine Edition field types to the corresponding field types in MaxCompute and ApsaraDB RDS for MySQL. Use these mappings when you configure a data source.
Mappings between OpenSearch field types and MaxCompute field types
Important
MaxCompute data sources support only five data types: STRING, BOOLEAN, DOUBLE, BIGINT, and DATETIME.
For multi-value fields of integer, float, and double types, use a string type (VARCHAR or STRING) in MaxCompute and separate each value with"\x1D"('^]').
| OpenSearch Retrieval Engine Edition field type | MaxCompute field type |
|---|---|
| TEXT | String types such as VARCHAR and STRING |
| STRING | String types such as VARCHAR and STRING |
| INT8 | Single-value field: TINYINT. Multi-value field: string types such as VARCHAR and STRING |
| UINT8 | Single-value field: TINYINT. Multi-value field: string types such as VARCHAR and STRING |
| INT16 | Single-value field: TINYINT and SMALLINT. Multi-value field: string types such as VARCHAR and STRING |
| UINT16 | Single-value field: TINYINT and SMALLINT. Multi-value field: string types such as VARCHAR and STRING |
| INTEGER | Single-value field: TINYINT, SMALLINT, and INT. Multi-value field: string types such as VARCHAR and STRING |
| UINT32 | Single-value field: TINYINT, SMALLINT, and INT. Multi-value field: string types such as VARCHAR and STRING |
| INT64 | Single-value field: TINYINT, SMALLINT, INT, and BIGINT. Multi-value field: string types such as VARCHAR and STRING |
| UINT64 | Single-value field: TINYINT, SMALLINT, INT, and BIGINT. Multi-value field: string types such as VARCHAR and STRING |
| FLOAT | Single-value field: FLOAT and INT (integer values must be within the value range of FLOAT). Multi-value field: string types such as VARCHAR and STRING |
| DOUBLE | Single-value field: DOUBLE, FLOAT, and INT. Multi-value field: string types such as VARCHAR and STRING |
| LOCATION | String types such as VARCHAR and STRING |
| LINE | String types such as VARCHAR and STRING |
| POLYGON | String types such as VARCHAR and STRING |
| DATE | DATE |
| TIME | String types such as VARCHAR and STRING |
| TIMESTAMP | DATETIME and TIMESTAMP |
Mappings between OpenSearch field types and ApsaraDB RDS for MySQL field types
For multi-value fields of integer, float, and double types, use a string type (VARCHAR or STRING) in ApsaraDB RDS and separate each value with"\x1D"('^]').
| OpenSearch Retrieval Engine Edition field type | ApsaraDB RDS for MySQL field type |
|---|---|
| TEXT | String types such as VARCHAR |
| STRING | String types such as VARCHAR |
| INT8 | Single-value field: TINYINT. Multi-value field: string types such as VARCHAR and STRING |
| UINT8 | Single-value field: TINYINT. Multi-value field: string types such as VARCHAR and STRING |
| INT16 | Single-value field: TINYINT and SMALLINT. Multi-value field: string types such as VARCHAR and STRING |
| UINT16 | Single-value field: TINYINT and SMALLINT. Multi-value field: string types such as VARCHAR and STRING |
| INTEGER | Single-value field: TINYINT, SMALLINT, and INTEGER. Multi-value field: string types such as VARCHAR and STRING |
| UINT32 | Single-value field: TINYINT, SMALLINT, and INTEGER. Multi-value field: string types such as VARCHAR and STRING |
| INT64 | Single-value field: TINYINT, SMALLINT, INTEGER, and BIGINT. Multi-value field: string types such as VARCHAR and STRING |
| UINT64 | Single-value field: TINYINT, SMALLINT, INTEGER, and BIGINT. Multi-value field: string types such as VARCHAR and STRING |
| FLOAT | Single-value field: FLOAT, NUMERIC, and INTEGER (integer values must be within the value range of FLOAT). Multi-value field: string types such as VARCHAR and STRING |
| DOUBLE | Single-value field: DOUBLE, NUMERIC, FLOAT, and INTEGER. Multi-value field: string types such as VARCHAR and STRING |
| LOCATION | String types such as VARCHAR and STRING |
| LINE | String types such as VARCHAR and STRING |
| POLYGON | String types such as VARCHAR and STRING |
| DATE | DATE |
| TIME | TIME |
| TIMESTAMP | DATETIME and TIMESTAMP |