Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

how to met required condition

hi team,

Can any one  help to my requirement.i have  2 tables,if req  value= wh1 value exit lopp other wise it has to check wh2,wh3...like so on..

when ever condition met need  to exit loop.

table1

S.nowh1wh2wh3wh4wh5wh6
1abcdef
2bcdefg
3cdefgh
4defghi
5efghij
6fghijk
7ghijkl
8hijklm
9ijklmn
10jklmno

table2

S.noreq

1

a
2b
3c
4d
5e
6f
7g
8h
9i
10j
11k
12l
13m
14n
15o
2 Replies
petter
Partner - Champion III
Partner - Champion III

Is this something you would have done in the load script or in the app at runtime?

Could you please be more specific about your requirements? What do you mean by loop and exit the loop?

What is the condition that should be met? Is it each value of wh1 column against each value of req column with matching S.no?

maxgro
MVP
MVP

Maybe this?

1.png

if yes this is the script

A:

LOAD S.no,      wh1,      wh2,      wh3,      wh4,      wh5,      wh6

FROM [https://community.qlik.com/thread/198984] (html, codepage is 1252, embedded labels, table is @1);

B:

LOAD S.no,      req

FROM     [https://community.qlik.com/thread/198984] (html, codepage is 1252, embedded labels, table is @2);

for i=1 to 6

  MapWh$(i):     Mapping LOAD wh$(i), 'wh$(i)' Resident A;

next;


Left Join (B)

load

  S.no,

  ApplyMap('MapWh1', req,

  ApplyMap('MapWh2', req,

  ApplyMap('MapWh3', req,

  ApplyMap('MapWh4', req,

  ApplyMap('MapWh5', req,

  ApplyMap('MapWh6', req, 'No match'

  )))))) as Result

Resident B;