Delete a search index

更新时间: 2026-01-20 21:39:23

Prerequisites

Notes

A search index cannot be recovered after it is deleted. Proceed with caution.

Parameters

Parameter

Description

TableName

The name of the data table.

IndexName

The name of the search index.

Example

The following example shows how to delete a search index.

/// <summary>
/// Deletes a search index.
/// </summary>
/// <param name="otsClient"></param>
public static void DeleteSearchIndex(OTSClient otsClient)
{
    // Set the data table name and the search index name.
    DeleteSearchIndexRequest request = new DeleteSearchIndexRequest(TableName, IndexName);
    // Call otsClient to delete the search index.
    DeleteSearchIndexResponse response = otsClient.DeleteSearchIndex(request);
}

References

  • If an existing search index does not meet your requirements, you can create a new search index or modify the schema of the search index to add, delete, or modify indexed fields. For more information, see Delete a search index and Dynamically modify a schema.

  • In addition to search indexes, Tablestore also provides an SQL engine, a table engine, and secondary indexes for data queries. You can choose a query method based on your query scenario. For more information, see Index overview and Index selection.

上一篇: Query the description of a search index 下一篇: Data types
阿里云首页 表格存储 相关技术圈