Wildcards for Windows File System Subclients

You can use wildcards when you specify the content 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.

"<MR>." filters the files with same name as extension and not the folder

Example string with wildcard

What the example string matches

Examples of files that are filtered

<MR>.bak

<MR>.bak would filter all the files that have .bak extension

  • bak.bak

  • file_1.bak

  • file_n.bak

* (Any Number of Characters)

Example string with wildcard

What the example string matches

Examples of files and folders that are backed up

*.docx

All files that have the .docx file extension.

Are backed up:

  • Status.docx

  • agenda.docx

C:\Agenda\*.docx

All files that meet the following criteria:

  • Are in the C:\Agenda folder

  • Have the .docx file extension

Are backed up:

  • C:\Agenda\Status.docx

  • C:\Agenda\agenda.docx

a*.dll

All files that meet the following criteria:

  • Have a file name that begins with "a".

  • Have the .dll file extension

Are backed up:

  • alsvc.dll

  • Advdcc.dll

C:\Finance\Agenda\*

All files in the C:\Finance\Agenda folder.

If there are folders in the Agenda folder, then no files in those sub-folders are backed up.

Are backed up:

  • C:\Finance\Agenda\accounts.xlsx

  • C:\Finance\Agenda\users.docx

Are not backed up, because they are in a sub-folder:

  • C:\Finance\Agenda\Users\users.docx

  • C:\Finance\Agenda\Accounts\accounts.docx

? (A Specific Number of Characters)

Example string with wildcard

What the example string matches

Examples of files and folders that are backed up

access?

All files and folders 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 folders 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 folders and files 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 folders that are backed up

agenda[1-5].txt

Files from agenda1.txt to agenda5.txt.

Are backed up:

  • agenda1.txt

  • agenda2.txt

  • agenda3.txt

  • agenda4.txt

  • agenda5.txt

agenda1[0-9][0-9][0-9].txt

Files from agenda1000.txt to agenda1999.txt.

Are backed up:

  • agenda1000.txt

  • agenda1001.txt

  • ...

  • agenda1999.txt

agenda[1-3][0-9]

Files from agenda10 to agenda39.

Are backed up:

  • agenda10.txt

  • agenda11.txt

  • ...

  • agenda39.txt

agenda[10-39]

Files and folders that have names that begin with agenda1, agenda0, agenda3, or agenda9.

Are backed up:

  • agenda1.docx

  • agenda0.docx

  • agenda3.docx

  • agenda9.docx

Are not backed up:

  • agenda10.docx

  • agenda39.docx

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

Example string with wildcard

What the example string matches

Examples of files and folders that are backed up

C:\Windows\[!AEIOU]*.docx

All files that:

  • Are in the C:\Windows folder

  • Have names that begin with a letter other than A, E, I, O, or U

  • Have the .docx file extension

Are backed up:

  • C:\Windows\File1.docx

  • C:\Windows\budget.docx

    Are not backed up:

  • C:\Windows\accounts.docx

  • C:\Windows\users.docx

<P:e=x> (An Escape Character)

x is an escape character that you define in order to treat a wildcard character, such as square brackets [ ], as a literal character.

To treat wildcard characters, such as square brackets [ ], as literal characters, define any character as an escape character using a <P:e=x> statement, and include the escape character immediately before each wildcard character that you want to treat as a literal character.

You can also use the escape character as a literal character by prefixing it with another escape character.

Example string with wildcard

Examples of files and folders that are backed up

<P:e='>C:\report'[finance'].docx

Is backed up:

  • C:\report[finance].doc

<P:e=’>C:\Agenda’[Report’]’’2011’’Financials.docx

Is backed up:

  • C:\Agenda[Report]’2011’Financials.docx

<P:e=~>C:\share\folder~[x~]\***

Is backed up:

  • C:\share\folder[x]

<P:e=~>C:\DATA\folder~[[3-5]~]\***

Are backed up:

  • C:\DATA\folder[3]

  • C:\DATA\folder[4]

  • C:\DATA\folder[5]

<P:e=~>C:\DATA\folder~[[!3-5]~]\***

Are not backed up:

  • C:\DATA\folder[3]

  • C:\DATA\folder[4]

  • C:\DATA\folder[5]

Loading...