# Wildcards for Object Storage Content Groups

You can use a wildcard to represent one or more characters when you define the content for backups and filters for a subclient.

The search for subclient content is not case-sensitive.

Note

If the subclient content consists of wildcard characters and no eligible files are found for the backup, the backup operation can still successfully complete.

## * (Any Number of Characters)

Example string with wildcard | What the example string matches | Examples of files and directories that are backed up
--- | --- | ---
*.docx | All files that have the .docx file extension. | Are backed up: Status.docx agenda.docx
/Data/*.docx | All files that: Are in the /Data directory Have the .docx file extension | Are backed up: /Data/Status.docx /Data/agenda.docx
a*.so | All files that: Have names that begin with the letter "a" Have the .so file extension | Are backed up: alsvc.so advdcc.so
/Finance/Agenda* | All files and directories that: Are in the /Finance directory Have names that begin with "Agenda" | Are backed up: /Finance/agenda.pdf /Finance/agenda.docx

## ? (A Single Character)

Example string with wildcard | What the example string matches | Examples of files and directories that are backed up
--- | --- | ---
access? | All files and directories that have a name that begins with "access", followed by any 1 character. | Are backed up: access1.pdf Access2.pdf Are not backed up, because "access" is followed by a number of characters other than 1: access.pdf Access15.pdf
access?? | All files and directories that have a name that begins with "access", followed by any 2 characters. | Are backed up: access15.pdf Access20.pdf Are not backed up, because "access" is followed by a number of characters other than 2: access1.pdf Access2.pdf
Class?report | All files and directories that have a name that: Begins with "Class" Has 1 character between "Class" and "report" Ends in "report" | Are backed up: Class1report.docx Class2report.docx Are not backed up, because "Class" is followed by a number of characters other than 1: Classreport.docx Class12report.docx

## [n] (A Range of Characters)

Numbers within square brackets are treated as single digits, and a dash between two digits indicates the complete range of numbers between those two digits.

Example string with wildcard | What the example string matches | Examples of files and directories that are backed up
--- | --- | ---
/[a-m]* | All files that: Are on the / (root) partition Begin with the letters a-m | Are backed up: /root/accounts.pdf /root/my_file.docx Is not backed up: /root/users.docx
/[AEIOU]*.docx | All files that: Have names that begin with A, E, I, O, or U Have the .docx file extension | Are backed up: /root/accounting/accounts.docx /root/accounting/users.docx Are not backed up: /root/accounting/File1.docx /root/accounting/budget.docx
/Finance/report[1-47-9] | All files and directories that: Are in the /Finance directory Have a name that begins with "report", followed by any number in the specified ranges | Are backed up: /Finance/report1 /Finance/report2 /Finance/report4 /Finance/report7 /Finance/report8 /Finance/report9
/Department-[A-CS] | All files and directories that have names that begin with "Department-", followed by A-C, or S. | Are backed up: Department-A Department-B Department-C Department-S Is not backed up: Department-D

## [!n] (The Negation of a Range or a Set of Characters)

Example string with wildcard | What the example string matches | Examples of files and directories that are backed up
--- | --- | ---
/root/[!AEIOU]*.docx | All files that: Are in the /root directory Have names that do not start with A, E, I, O, or U Have the .docx file extension | Are backed up: /root/File1.docx /root/budget.docx Are not backed up: /root/accounts.docx /root/users.docx

## ** (Any Number of Characters Across Any Number of Path Levels)

Example string with wildcard | What the example string matches | Examples of files and directories that are backed up
--- | --- | ---
/**/move.cpp | All files that have the name move.cpp. | Are backed up: /root/newapp/move.cpp /opt/kde3/src/move.cpp
/etc/** | All files and directories under the /etc directory, including all sub-directories. | Are backed up: /etc/budget /etc/users.docx

## *** (Filters and Exceptions)

Use this wildcard in the following scenarios:

- To filter the directory/library and the objects that are under it.

- To add an exception to a filter.

Example string with wildcard | What the example string matches | Examples of files and directories that are backed up
--- | --- | ---
/QSYS.LIB/ABC.LIB/*** | This string filters ABC.LIB and its contents. |
The filter QSYS.LIB/*** and the exception /QSYS.LIB/ABC.LIB/*** | This string backs up ABC.LIB and its contents. |

×

Loading...