I was also thinking about that solution, like I described above.
But the Problem here is, I have to know before hand what file names I want to load.
If the file is not found, the script returns an error.
I want to do it over different kind of files and and I do not know every combination before hand.
Furthermore I want to build the names on the fly, because I want to use it in a script for On Demand App Generation.
Of course I could search in a folder, match the findings with my pattern and loop trough every combination, but this script gets nasty and blown up for a simple regex expression.
I have some solutions I could work with but my question, when Qlik supports wildcards, does they also support further Wildcards as * which are not documented yet???
does they also support further Wildcards as * which are not documented yet???
> I am also new in QlikSense so not sure about it.
I am still not getting your question. You are making 2 contradict statement.
In your original post you are saying that you want file_2 & file_3.qvd and
In You are earlier reply you are saying You want solution where you don't have file name in your hand before load.
So how qlik understand which file to load or which not??
Another logic in my mind is If you dont have file in your hand before load or you don't want to update it in script.
Then You can try below logic
1: Maintain excel file where you insert filename which you want to load
2: Load excel in script & use that column in for loop.
I don't think that there are further wildcards available and that you could apply any regex-logic by loading files. I'm not absolutely sure but I believe that Qlik has no own logic for handling files else they just use windows dll's for it and AFAIK there are also only * and ? as wildcards defined.
Beside this I don't think that a for each approach with dirlist/filelist is ugly. It's fast and quite often there are further conditions like checking the filetime/filesize, handling different data-structures, file-formats, where-clauses and so on - and at least there you will need some more efforts to implement it.
Further the help-example for the loop indicates by using sub-routines how it could be nicely handled - means putting everything in a routine which again called the necessary routines and this could be put in an include-variable and used globally within your whole environment. And then its just enough to call the routine with the needed parameters.