You need to enable JavaScript to run this app.
导航

DropIndex

最近更新时间2024.04.16 13:11:56

首次发布时间2023.12.21 19:03:20

概述

DropIndex 用于删除指定数据集 Collection 的指定索引 Index。

请求参数

参数

类型

是否必选

参数说明

collectionName

string

指定要删除索引所属的 Collection 名称。

  • 只能使用英文字母、数字、下划线_,并以英文字母开头,不能为空。
  • 长度要求:[1, 128]。
  • Collection 名称不能重复。

indexName

string

指定要删除的 Index 名称。

  • 只能使用英文字母、数字、下划线_,并以英文字母开头,不能为空。
  • 长度要求:[1, 128]。
  • 索引名称不能重复。

示例

请求参数

err := service.DropIndex("go", "goIndex")
if err != nil {
    fmt.Println(err)
}

返回值

Go 调用执行上面的任务,执行成功无返回信息。