Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Coming your way, the Qlik Data Revolution Virtual Summit. October 27-29. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator II
Creator II

How to find a single record in a data source

Hi Friends,

I have following data table in my QV doc. 

Screenshot_1.png

From the data table I want to mark record highlighted in yellow as Y in a separate field namely  'FLAG'  In other words all single record (RISK) with TRN_TYPE= 'R' should be marked as 'Y' in the FLAG field in Data load script. Kindly help me with syntax for it .

1 Reply
Highlighted
Creator II
Creator II

When loading your data in the script, just create another field called FLAG. Like:

LOAD [POLICY_NO],

     [R_SEQ],

     [RISK],

    [TRN_TYPE],

    [FROM_DATE],

    if (count([RISK]) = 1 and [TRN_TYPE] = 'R', 'Y', 'N') as [FLAG]

FROM ….