Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to use FROM for several LOADS

Hi,

I wish to use this 'from' sentence for [j_2008.TXT] , [j_2009.TXT], etc without repeating all the script.

Does it exist something like 'FROM ([j_2008.TXT],[j_2009.TXT] ...)' ?

FROM

[j_2008.TXT]

(txt, codepage is 1252, no labels, delimiter is ';', msq, header is 8 lines, filters(

ColXtr(1, RowCnd(CellValue, 1, StrCnd(start, '!Period=')), 19),

Replace(19, top, StrCnd(null)),

ColXtr(1, RowCnd(CellValue, 1, StrCnd(start, '!Scenario=')), 20),

Replace(20, top, StrCnd(null)),

ColXtr(1, RowCnd(CellValue, 1, StrCnd(start, '!Year=')), 21),

Replace(21, top, StrCnd(null)),

ColXtr(1, RowCnd(CellValue, 1, StrCnd(start, '!JOURNAL=')), 10),

Replace(10, top, StrCnd(null)),

ColXtr(1, RowCnd(CellValue, 1, StrCnd(start, '!DESC=')), 11),

Replace(11, top, StrCnd(null)),

ColXtr(2, RowCnd(CellValue, 1, StrCnd(start, '!JOURNAL=')), 12),

Replace(12, top, StrCnd(null)),

ColXtr(3, RowCnd(CellValue, 1, StrCnd(start, '!JOURNAL=')), 13),

Replace(13, top, StrCnd(null)),

ColXtr(4, RowCnd(CellValue, 1, StrCnd(start, '!JOURNAL=')), 14),

Replace(14, top, StrCnd(null)),

ColXtr(5, RowCnd(CellValue, 1, StrCnd(start, '!JOURNAL=')), 15),

Replace(15, top, StrCnd(null)),

ColXtr(6, RowCnd(CellValue, 1, StrCnd(start, '!JOURNAL=')), 16),

Replace(16, top, StrCnd(null)),

ColXtr(7, RowCnd(CellValue, 1, StrCnd(start, '!JOURNAL=')), 17),

Replace(17, top, StrCnd(null)),

ColXtr(8, RowCnd(CellValue, 1, StrCnd(start, '!JOURNAL=')), 18),

Replace(18, top, StrCnd(null)),

Remove(Row, RowCnd(CellValue, 1, StrCnd(start, '!')))

));

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Try using a wildcard:

FROM

[j_200*.TXT]

....

or a for each .. next loop

View solution in original post

1 Reply
swuehl
MVP
MVP

Try using a wildcard:

FROM

[j_200*.TXT]

....

or a for each .. next loop