Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Help with Set Analysis - And Or

Hi

I'm trying to bring back a set of students in Qlikview, who meet a certain set of criteria, namely they are either in (Term of Entry + 200) and or in (Term of Entry + 300), I tried the code below but it only brings back students in (Term of Entry + 300) regardless of whether they are in (Term of Entry + 200)

.

Any ideas how to bring back students who are in:  (Term of Entry + 300) and / or (Term of Entry + 200), but to only count each student once.

(

count(Distinct{$<

LevelCode = {'UG'},

ExtractType = {1},

YearofProgram = {'3','4'},

RegStatusCode = {'RE', 'RS', 'RP', 'WU'},

InstanceTerm = {$(= only (TermofEntry)+ 200)},

InstanceTerm = {$(= only (TermofEntry)+ 300)},

CollegeCode = {'AF'},

DegreeCode = {'BA', 'BSC', 'BENG', 'LLB', 'MENG', 'MPHYS'}, ProgramModeofStudy = {'FT'}

>} 
Pidm))

2 Replies
Not applicable
Author

Hi,

Try this:

(

count(Distinct{$<

LevelCode = {'UG'},

ExtractType = {1},

YearofProgram = {'3','4'},

RegStatusCode = {'RE', 'RS', 'RP', 'WU'},

InstanceTerm = {$(= only (TermofEntry)+ 200)} +  {$(= only (TermofEntry)+ 300)},

CollegeCode = {'AF'},

DegreeCode = {'BA', 'BSC', 'BENG', 'LLB', 'MENG', 'MPHYS'}, ProgramModeofStudy = {'FT'}

>} 
Pidm))

Hope it helps.

Regards,

-Khaled.

MayilVahanan

HI

Try like this

InstanceTerm = {$(= only (TermofEntry)+ 200)} ,  {$(= only (TermofEntry)+ 300)},

it return the instanceterm where TermofEntry+200 or TermEntry+300.

For ex: IF TermOfEntry = 200,

then it checks the instanceTerm = 400,500 and return the values. Are you need like this?

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.