Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
damian_spyra
Contributor III
Contributor III

Result selection - Need Help!

Hi all,

i have follow issue:

I have patient data, with correspondent medical orders and belonging checkup results.

One single test can have two different result classes.

Data structure:

Order ID,     Test ID,     Result class,      Result

     0               1               MHK                10                  

     0               1                  A                  15

     0               2               MHK                12

     0               3               MHK                11

     0               4                  A                  15

What I'm trying to do, is to determine if there exists the Result class MHK inside one test. In case of existing MHK class i want to show only MHK Result and "hide" the A Result class. In other case the A Result class should be pointed.

Thanks for any help!            

2 Replies
hic
Former Employee
Former Employee

If you want to do it in the script, then there is a simple solution:

LOAD [Order ID], [Test ID], [Result class], Result FROM Sourcetable

     WHERE [Result class]='MHK';

LOAD [Order ID], [Test ID], [Result class], Result FROM Sourcetable

     WHERE not Exists([Test ID]);

damian_spyra
Contributor III
Contributor III
Author

Hello Henric,

thank you for your idea, it works well.

I've been thinking about my issue. If i make it in script, i will lose the possibility to have/show both Result information  if required. It would be interesting to solve this problem statement with for example an set analysis formula.

I'm not sure if it's possible.