[Solved] List Files With Multiple Name Patterns

Hi,

We have created a script that would accept the an indicator as a parameter and archive files present in a directory. The indicator would drive what the name pattern of the files to be archived should be.
If the indicator is 1, then the pattern to look out for is FACT*.
If the indicator is 2, then the patterns to look out for are IMS* and DWH*.

Now I would like to know if there's a way to tar 2 sets of patterns in one command. So, when the indicator is 2, my command would look like

tar -cvzf $ARCHIVE_FILE_NM (IMS* or DWH*)

Kindly advise

Have you tried:

tar -cvzf $ARCHIVE_FILE_NM IMS* DWH*

It was that easy!? Thanks a ton!:b: