You can call the DeleteSearchIndex operation to delete a search index created for a table.


  • The OTSClient instance is initialized. For more information, see Initialization.
  • A data table is created and data is written to the table.
  • A search index is created for the table. For more information, see Create search indexes.


Parameter Description
tableName The name of the table.
indexName The name of the search index.


private static void deleteSearchIndex(SyncClient client) {
    DeleteSearchIndexRequest request = new DeleteSearchIndexRequest();
    request.setTableName(TABLE_NAME); // Set the name of the table.
    request.setIndexName(INDEX_NAME); // Set the name of the search index.
    client.deleteSearchIndex(request); // Call client to delete the search Index.