All Products
Search
Document Center

Tablestore:Delete mapping tables

Last Updated:Nov 29, 2024

If you no longer require a mapping table, you can execute the DROP MAPPING TABLE statement to delete the mapping table. You can delete multiple mapping tables in a single request.

Note

The DROP MAPPING TABLE statement does not delete the tables in Tablestore.

Syntax

DROP MAPPING TABLE [IF EXISTS] table_name,...;

Parameters

Parameter

Required

Description

table_name

Yes

The name of the mapping table. You can specify the names of multiple mapping tables in a single request. Separate multiple mapping table names with commas (,).

IF EXISTS

No

Specifies that a success response is returned regardless of whether the mapping table exists. If you do not specify IF EXISTS, a success response is returned only if the mapping table exists.

Examples

The following sample code provides an example on how to create a mapping table named exampletable:

DROP MAPPING TABLE IF EXISTS exampletable;

References

  • If an attribute column of a data table changes, you can execute the ALTER TABLE statement to modify the mapping table that is created for the data table. For more information, see Update attribute columns of mapping tables.

  • If you want to accelerate data queries and computing by executing SQL statements, you can create a secondary index or a search index. For more information, see Index selection policy and Computing pushdown.

  • You can also use computing engines, such as MaxCompute, Spark, Hive, HadoopMR, Function Compute, Flink, and PrestoDB, to compute and analyze data in tables. For more information, see Overview.

  • If your business requires multi-dimensional queries and data analysis, you can create a search index and specify the required attributes as the fields of the search index. Then, you can use the search index to query and analyze data. For example, you can use a search index to perform queries based on non-primary key columns, Boolean queries, and fuzzy queries. You can also use a search index to obtain the maximum and minimum values, collect statistics about the number of rows, and group query results. For more information, see Search Index.