Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

karan_kn
Contributor

Fields not syncing in the table

Fields are not syncing when I use if condition

Script:

Table:
LOAD ID,
key,
value,
If(key='A', source_value) as FieldA,
If(key='B', source_value) as FieldB,
If(key='C', source_value) as FieldC;
SQL SELECT *
FROM dbo.Table1;

 

Output:

Capture.JPG

2 Replies
Partner
Partner

Re: Fields not syncing in the table

With your code you still have 3 different rows rather than combining them into 1 single row.
What you are asking for is the opposite of crosstable load. so you need generic load.
check below link for details
https://community.qlik.com/t5/Qlik-Design-Blog/The-Generic-Load/ba-p/1473470
Highlighted

Re: Fields not syncing in the table

Or use a group by or even applymap but as Dilipranjith says original data has 3 rows, so 3 rows are loaded and something has to be done to merge in one row.