UntarFile

Summary

Use the UntarFile function to extract the contents of a tar file to the Connect SFTP server file system.

Syntax

TarFile(FilePath='<path to source tar file>', 
    Destination='<target untar directory>' 
    [, Overwrite=<true|false>])

Parameters

Parameter Description
FilePath (Required) Specifies the source tar file to unpack.

For example:

  • FilePath=’my_source_file.tar’
  • FilePath=’/my_source_file.tar’
  • FilePath=’/a_dir/a_sub_dir/my_source_file.tar’
Destination (Required) The target directory path. The function automatically creates the destination directory (and any sub-directories for the tar file entries) if they do not already exist.

For example:

  • Destination=’/outbound_files’
  • Destination=’/hr_data_extracts/untarred’
  • Destination=’/’ — Unpacks the contents of the source tar file to the root directory.
Overwrite (Optional) Overwrite target files or directories from the source tar file if the they already exist on the SFTP file system. The default is false.

Return Type

The function returns a status result set containing information about each file extracted from the source tar file.

Details

Connect is integrated with the Xactly SFTP server, connectftp.xactlycorp.com.

Connect file commands can read and write files and manipulate directory structures located on the SFTP file system. An SFTP account is not required to use these commands. However, an account is required to access the file system using SFTP clients. Contact Xactly Customer Support to set up an SFTP account, if necessary.

You can use an SFTP client to get and put files on the Xactly SFTP server. Valid SFTP login credentials are required to transfer files using SFTP. Connect users, however, do not need SFTP credentials to use Connect file functions with files located on the SFTP server.

Examples

call UntarFile(FilePath='/unprocessed_files/my_tar.tar',
    Destination='/untarred_files');