Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Use of If(Not Match) function with a second restriction.

I have the following multi box:

Screen Shot 2015-12-16 at 23.04.07.png

I am restricting values displayed in this multi box with the following expression:

=If(Not Match(_View, 'Patent Analytics', 'FDA Analytics', 'Generic Products Opportunity Analysis', 'Shopping Analytics', 'Pharmacy Analytics'), _View)


This gives the following restricted values in the multi box:


Screen Shot 2015-12-16 at 23.04.36.png

I now want to add a second restriction to the expression as follows:


'PATENTS' < 0


I only want the values to be restricted by the if(Not Match) function when the field 'PATENTS' < 0


How can the two expressions be combined to give the desired result?


Regards.



18 Replies
Anonymous
Not applicable
Author

HI SUNNY

If i get my model with the right associations, the expression should be something like:

=If('PATENTS' > 0, _View, If(Not Match(_View, 'Patent Analytics', 'FDA Analytics', 'Generic Products Opportunity Analysis', 'Shopping Analytics', 'Pharmacy Analytics'), _View))


A user with a 'PATENT' flag of 1 should be able to see the all the contents of the multi box and a user with a 'PATENT' flag of zero should only see the restricted list.

settu_periasamy
Master III
Master III

Hi Christopher,

Try this

=if(GetFieldSelections(PATENTS)=0,

If(Not Match(_View, 'Patent Analytics', 'FDA Analytics', 'Generic Products Opportunity Analysis', 'Shopping Analytics', 'Pharmacy Analytics')

, _View),_View)

HirisH_V7
Master
Master

Hi ,

You can write like this in your back end.

Table:

LOAD * INLINE [

    View, Patents

    Patent Analytics,1

    FDA Analytics,2

    Generic Products Opportunity Analysis,

    Shopping Analytics,

    Pharmacy Analytics,4

]Where len(Patents)>0;

Output:

if Not match.PNG

This will bring all the records which are having patents.

Hope this helps,

Regards,

Hirish

HirisH
“Aspire to Inspire before we Expire!”
HirisH_V7
Master
Master

Hi ,

You haven't mapped your Dashboard(Field) with Patents(Field),

Back end :


View:

LOAD * Inline [

_View

Dashboard ,PATENTS

Point in Time Reporting,0

Leading Therapeutic Classes (Level 1),0

Leading Therapeutic Classes (Level 3),1

Leading Companies,0

Leading Products,0

Leading New Products,1

Payment Method Summary,0

Co-payment Summary,0

Fastest Growing Therapeutic Classes (ATC3),1

Comparative Analysis,1

Trend Analysis,0

Product Analytics,0

Generic Products Opportunity Analysis,1

Patent Analytics,1

FDA Analytics,1

Shopping Analytics,1

Pharmacy Analytics,0

];

//Use this at back end where Len(PATENTS)

>0 if you dont want 0 patents or else check out front end

and

ANALYTICS:

Concatenate(View)

LOAD PATENTS,

    FDA,

    GENERICS,

    SHOPPING,

    PLAZA_ANALYTICS

FROM

[..\Data Files\SectionAccess.xlsx]

(ooxml, embedded labels, table is SectionAccess);

There by mapping is done

Front end:

You can Use this expression:

=if(len(PATENTS)>0 ,If(Not Match(_View, 'Patent Analytics', 'FDA Analytics',

'Generic Products Opportunity Analysis', 'Shopping Analytics', 'Pharmacy Analytics'), _View))

Hope this Helps,

PFA,

REgards,

Hirish

HirisH
“Aspire to Inspire before we Expire!”
Anonymous
Not applicable
Author

Dear Hirish

Thank you very much for you input.  I will work on it and advise accordingly.

Regards.

Anonymous
Not applicable
Author

Thanks Hirish

Anonymous
Not applicable
Author

Many thanks Settu, i will try that out

Anonymous
Not applicable
Author

Hi Hirish

Is there a way of linking the say 'PATENT' field with Section Access so that a user with a 'PATENT' flag of say 1 within section access will be able to access the 'Patent Analytics' menu selection, a user with a 'FDA' flag of 1 will also be able to access the 'FDA Analytics' menu selection and so on?

HirisH_V7
Master
Master

Pleasure ..

Thank u

HirisH
“Aspire to Inspire before we Expire!”