Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

automation-undo

Undo behavior of a Crunch Automation Script


Description

There are two ways to revert the output of a script:

  • undoScript() - A "softer" delete of a script's created artifacts and variables, or

  • revertScript() - A "harder" revert that returns the dataset to the state it was before running such script.

Usage

undoScript(dataset, x)

revertScript(dataset, x)

scriptSavepoint(x)

## S4 method for signature 'CrunchDataset,Script'
undoScript(dataset, x)

## S4 method for signature 'CrunchDataset,ANY'
undoScript(dataset, x)

## S4 method for signature 'CrunchDataset,Script'
revertScript(dataset, x)

## S4 method for signature 'CrunchDataset,ANY'
revertScript(dataset, x)

## S4 method for signature 'Script'
scriptSavepoint(x)

Arguments

dataset

A CrunchDataset

x

A Script or index for a ScriptCatalog (generally a number)

Details

The difference between both is that a hard revert restores the dataset, as it drops all ensuing scripts and their output (artifacts and variables), while an undo only deletes the artifacts and variables created by this script, but changes made by other scripts and this script's record will remain in place.

The function scriptSavepoint() gets the version object

Value

For undoScript() and revertSctipt(), invisibly return the updated dataset. For scriptSavePoint() a version list object that can be used in restoreVersion().

See Also


crunch

Crunch.io Data Tools

v1.28.0
LGPL (>= 3)
Authors
Greg Freedman Ellis [aut, cre], Jonathan Keane [aut], Mike Malecki [aut], Neal Richardson [aut], Gordon Shotwell [aut]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.