Today, I will discuss about the “Wildcards in Pentaho”. I have tried to cover all possible Scenarios.

Use the below wildcard for below mentioned Scenarios.

1. Get all files present inside a particular Directory.
.+

2. Get all CSV files.
.+\.csv

3. Get all CSV files having special character like UnderScore (_)
.+._.+\.csv

4. Get all CSV files starting with Particular Pattern . For Example abc*****.csv
abc.+\.csv

5. Get all CSV files having pattern in between.For example ***abc***.csv
.+.abc.+\.csv

6. Get all CSV files which are ending with Numbers.
.+[0-9]\.csv

7. Get all CSV files starting with particular Pattern and ending with numbers.
abc.+[0-9]\.csv

8. Get all CSV files having numbers with defined length.For example test_123478.csv
.+[0-9]{8}\.csv

9. Get all CSV files with uppercase only.
.+[ENG:A-Z]\.csv

10. Get all CSV files with lowercase only.
.+[ENG:a-z]\.csv

11. Get all CSV files having uppercase or lowercase or both .
.+([ENG:a-z]|[ENG:A-Z])\.csv

12. Get all CSV files having lowercase and numbers in the file name.
.+([ENG:a-z][0-9])\.csv

13. Get all CSV files having particular Date Pattern. for example test_20190522.csv.
.+${CURRENT_DATE}\.csv

You need to design ETL code for this as we need to set the current date and then change it to String using “select Values” Component.Sharing the SS step by Step for the same.

If anyone has any Query regarding wildcards, please post your Queries to techiesavy07@gmail.com