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: 
zied_ahmed1
Specialist
Specialist

resolve problem without touching datamodel

Hello everybody,

Thanks for your answers. I attached an example of the application.Just one thing when I selected Color in Exist  I can't select it in not exist

so now for example when I select color in Exist and  Entreprise  in not exist I will have a table with just one row with the hostname X

Hope you understand how I need to do

Thanks

omarbensalem

1 Solution

Accepted Solutions
OmarBenSalem

For me the easiest way to achieve this is to add 2 columns in your final table:

Controler1:

=if([Not Exists]='Statut', aggr(sum({<Statut={0}>}1),Hostname) ,

if([Not Exists]='Entreprise', aggr(sum({<Entreprise={0}>}1),Hostname) ,

if([Not Exists]='Color', aggr(sum({<Color={0}>}1),Hostname) ,Statut )))

Controler2:

=if(Exist='Statut', aggr(sum({<Statut={1}>}1),Hostname) ,

if(Exist='Entreprise', aggr(sum({<Entreprise={1}>}1),Hostname) ,

if(Exist='Color', aggr(sum({<Color={1}>}1),Hostname) ,Statut )))

Result:

Example,

exists ; Statut

No exists : color:

Capture.PNG

=>

Capture.PNG

View solution in original post

12 Replies
OmarBenSalem

what are those?

Capture.PNG

zied_ahmed1
Specialist
Specialist
Author

Sorry...

PicPic.PNG

zied_ahmed1
Specialist
Specialist
Author

if for exemple we select Statut Exist and Entreprise Not Exist we will have just the row Hostname x.

OmarBenSalem

Now please explain in better words with some examples;

if u select statut in exist what happens?

if u select statut in exist and rentrprise in not exists, what should happen?

etc

OmarBenSalem

but u can't select both Statut in exist and ntreprise in Noty exists:

Capture.PNG

zied_ahmed1
Specialist
Specialist
Author

Okay..

I used to do the same model but in the real model when you select Color in Exist field it will be disable in the field not Exist

For the example like i said , if select Statut in Exist (Exist is like Statut = 1 in table ) and Entreprise in Not Exist (it means 0 in the table )

-> I will display just the row of hostname X

PicPic.PNG

OmarBenSalem

Then reattach an application like the real model, PLEASE.

zied_ahmed1
Specialist
Specialist
Author

I can't export the application that's why

OmarBenSalem

For me the easiest way to achieve this is to add 2 columns in your final table:

Controler1:

=if([Not Exists]='Statut', aggr(sum({<Statut={0}>}1),Hostname) ,

if([Not Exists]='Entreprise', aggr(sum({<Entreprise={0}>}1),Hostname) ,

if([Not Exists]='Color', aggr(sum({<Color={0}>}1),Hostname) ,Statut )))

Controler2:

=if(Exist='Statut', aggr(sum({<Statut={1}>}1),Hostname) ,

if(Exist='Entreprise', aggr(sum({<Entreprise={1}>}1),Hostname) ,

if(Exist='Color', aggr(sum({<Color={1}>}1),Hostname) ,Statut )))

Result:

Example,

exists ; Statut

No exists : color:

Capture.PNG

=>

Capture.PNG