R/datastore_interactions.R
remove_datastore_files.Rd
The remove_datastore_files()
function requires that you are logged in to the VPN. You must also have permissions to edit the DataStore Reference in question, and the Reference must not be activated. In that case, remove_datastore_files()
detaches all files associated with the relevant DataStore Reference. Once the files are detached, they cannot be re-attached. Instead, updated files can be re-uploaded and attached to the reference via upload_data_package()
.
In the interactive mode (force = FALSE), you will be informed of the Reference number, Reference title, Reference creation date, and a list of files currently attached to the Reference. Once the files are successfully detached, you will be informed of a list of file names that were detached.
Note that remove_datastore_files()
is intended to be used with the data package Reference type on DataStore but in theory will allow you to remove files from ANY reference type.
remove_datastore_files(data_store_reference, force = FALSE, dev = FALSE)
if (FALSE) { # \dontrun{
remove_datastore_files(1234567)
remove_datastore_files(1234567, force = TRUE, dev = TRUE)
} # }