David Kakauridze
David Kakauridze

Reputation: 315

How to make if condition for columns in excel with QlikView script

Here's the objective, I'm loading EXCEL files to QlikView, but I don't know their particular structure, all I need is if they got column, named 'Date'. How can I make 'if condition' for this

Upvotes: 0

Views: 4291

Answers (1)

Jan
Jan

Reputation: 930

You can use FieldNumber('field ' ,'TableName') , see english QlikView Reference V11 , p. 337. Alas the reference does not tell which value will be given if the field does not exist - therefore I tried and it's 0. Next point is to get the TableName - just name your excel 'TestTable' for the example.

if FieldNumber('Date','TestTable') > 0 then
  let echo = 'Date present';
ELSE
  let echo = 'Date not present';

Upvotes: 1

Related Questions