• 清空表
TRUNCATE TABLE index_name [WITH RECONFIGURE]TRUNCATE TABLE products;Query OK, 0 rows affected (0.02 sec)POST /cli -d "TRUNCATE TABLE products"{
"total":0,
"error":"",
"warning":""
}$params = [ 'index' => 'products' ];
$response = $client->indices()->truncate($params);Array(
[total] => 0
[error] =>
[warning] =>
)最后更新于