--- title: "system.dataset.clearDataset" description: "Takes a dataset and returns a new dataset with all of the same column names, but all of the rows deleted." --- # system.dataset.clearDataset > Takes a dataset and returns a new dataset with all of the same column names, but all of the rows deleted. This function is used in **Python Scripting**. ## Description ## Client Permission Restrictions This scripting function has no [Client Permission](projects\project-properties\project-properties.md#client---permissions) restrictions. ## Syntax `system.dataset.clearDataset(dataset)` ### Parameters Type | Parameter | Description ------- | ------- | ------- Dataset | `dataset` | The starting dataset. If NULL, a NULL dataset will be returned. ### Returns **Dataset** - A new dataset that is a combination of the original two datasets. ### Scope All ## Code Examples ```python title="Example 1" # This example pulls in the dataset from a Table component, clears it, then writes the empty dataset back to the table. data = event.source.parent.getComponent('Table').data event.source.parent.getComponent('Table').data = system.dataset.clearDataset(data) ```