DELETE SEGMENT by ID
Function
This command is used to delete a segment based on the segment ID.
Syntax
DELETE FROM TABLE db_name.table_name WHERE SEGMENT.ID IN (segment_id1,segment_id2);
Parameters Description
Parameter |
Description |
---|---|
segment_id |
ID of the segment to be deleted. |
db_name |
Database name. If this parameter is not specified, the current database is used. |
table_name |
Name of a table in the specified database. |
Precautions
Segments cannot be deleted from stream tables.
Example
DELETE FROM TABLE CarbonDatabase.CarbonTable WHERE SEGMENT.ID IN (0);
DELETE FROM TABLE CarbonDatabase.CarbonTable WHERE SEGMENT.ID IN (0,5,8);
Response
Success or failure will be recorded in CarbonData logs.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot