![]() |
D.4 Reset Cluster and Delete From Cluster |
The RESET CLUSTER clustername
statement resets all values
in the current cluster row (or the entire cluster, if applicable) to
nulls and zeros. However, it does not remove the row, meaning the row
remains in place but with cleared values. When new rows are added,
this reset row is not reused. This statement also works for scalar
clusters.
In contrast, the DELETE FROM CLUSTER clustername
statement removes the current row entirely, making it available for
reuse when new rows are added. This deletion affects the cluster's
ordering, meaning the rows may no longer maintain their original
order. To remove all rows from a cluster — commonly used when reloading data — use:
delete from cluster xxx: all
where xxx
is the cluster name.
DELETE FROM CLUSTER
statement works by
removing the current row and replacing its data with the data from the last row
in the cluster. The cluster's size is then reduced by one. Operation | Effect | Reusability | Impact on Cluster |
---|---|---|---|
RESET CLUSTER |
Sets values in the row to nulls and zeros | Row remains but is not reused | Keeps order intact |
DELETE FROM CLUSTER |
Removes the row entirely | Row space is reused | Last row replaces deleted row, affecting order |
Hide Description
|
|
Enter or modify the code below, and then click on RUN |
Looking for the full power of Sheerpower?
Check out the Sheerpower website. Free to download. Free to use. |