Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
qs123
Contributor II
Contributor II

How to pick one value from column as variable

Hi Team,

I have one .txt file which only contains one word. I want the Qlik load script to pick that one word as variable.

  1. A third party system is generating a .TXT file and placing it in a fixed location.
  2. This file only contains 1 word. this word gets updated and overwritten every 6 hours.
  3. We need to pass that word as a filter in expression as set analysis.

How can Qlik load script pick that word and store it as variable?

So that we can use that variable in set analysis

Thank you

 

 

Labels (3)
1 Reply
NZFei
Partner - Specialist
Partner - Specialist

FileValue:
LOAD
@1 as WhateverName
FROM
[C:\FilePath\file.txt]
(txt, codepage is 1252, no labels, delimiter is '\t', msq);


let vVariable = peek('WhateverName',-1,'FileValue');