sas_file_upload: Upload a file to SAS

View source: R/file-upload.R

sas_file_uploadR Documentation

Upload a file to SAS

Description

Uploads a file to the remote SAS server.

Usage

sas_file_upload(local_path, sas_path)

Arguments

local_path

string; Path of file on local machine to be uploaded.

sas_path

string; Path to upload local file to on the remote SAS server.

Value

logical; value indicating if the operation succeeded.

See Also

Other file management functions: sas_file_copy(), sas_file_download(), sas_file_exists(), sas_file_remove(), sas_list()

Examples


# connect to SAS
sas_connect()

# create an example file
local_path <- tempfile(fileext = ".txt")
cat("some example text", file = tempfile_path)

sas_path <- readline(
  "Please provide the full path to upload an example file to (e.g., ~/example.txt)."
)
sas_file_upload(local_path, sas_path)

# cleanup
unlink(local_path)
sas_file_remove(sas_path)


sasquatch documentation built on Feb. 28, 2026, 1:07 a.m.