doc-exports/docs/dli/sqlreference/dli_08_0217.html
Su, Xiaomeng 76a5b1ee83 dli_sqlreference_20240227
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com>
Co-authored-by: Su, Xiaomeng <suxiaomeng1@huawei.com>
Co-committed-by: Su, Xiaomeng <suxiaomeng1@huawei.com>
2024-03-27 22:02:33 +00:00

5.0 KiB

Clearing Data

Function

This statement is used to delete data from the DLI or OBS table.

Syntax

1
TRUNCATE TABLE tablename [PARTITION (partcol1=val1, partcol2=val2 ...)];

Keywords

Table 1 Keywords

Parameter

Description

tablename

Name of the target DLI or OBS table that runs the Truncate statement.

partcol1

Partition name of the DLI or OBS table to be deleted.

Precautions

Only data in the DLI or OBS table can be deleted.

Example

1
truncate table test PARTITION (class = 'test');