FILEREMOVE

Name

fileremove

Location

The CLI executable is available at:

<installation_dir>/app/bin

Purpose

The fileremove command removes one or more files stored in a particular queue.

Files can be removed using one of the following methods:

  • deleting files that match one or more filter criteria

  • deleting all files contained in the queue

Synopsis

  • fileremove [options] <QueueManagerName> <QueueName>

  • fileremove -o REMALL <QueueManagerName> <QueueName>

  • fileremove -h

Description

The fileremove command removes one or more files currently contained in a specified queue.

The command supports filtering to restrict the operation to a subset of files based on metadata attributes.

This command is provided to ensure backward compatibility with legacy automation and operational scripts. See Compatibility Command Line Interfaces to map QueueManagerName and QueueName concepts into Data Mover Smart concepts.

Arguments

Argument
Description
Required

QueueManagerName

Name of the Queue Manager

Yes

QueueName

Name of the queue

Yes

Options

Option
Parameter
Description
Note

[-c]

CorrelId

Removes files(s) with the specified Correlation ID

Cannot be used with [-o] REMALL or [-c]

[-i]

IntNum

Removes the file with the specified Internal Number

Cannot be used with [-o] REMALL or [-c]

[-u]

UserId

User registered in Data Mover Smart

[-p]

UserPwd

Password of the UserId

[-o]

REMALL

Removes all files contained in the specified queue

Mutually exclusive with [-i] and [-c]

[-o]

NOLabel

Ignored

[-o]

NOBanner

Ignored

[-v]

Ignored

Selection rules

Exactly one selection method must be specified:

  • one of these filters: -i or -c

  • or -o REMALL

  • if no selection method is specified, the command fails

  • when filters are used only files matching all specified criteria are removed

Exit status

Code
Meaning
Typical cases

0

Operation completed successfully

Files matching the specified criteria have been removed

1

No matching files found

Filters are valid but no file in the queue matches the criteria; queue is empty when using -o REMALL

2

Operation failed

Missing mandatory parameters; no selection method specified; invalid number of arguments; wrong Queue Manager; wrong Queue; internal error during removal

Last updated