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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Pivot Table Data Restriction

Hi Team,

I need to restrict the data in the table to show only the Airlines having more than one between the Source and Destination.

I have posted my sample source data and required data.

Any ideas on achieving this?

Thanks in Advance.Please let me know if you need more details.

Thanks

Source Data:

OriginDestinationAirline
BangaloreBhopalJET AIRWAYS
CalicutSPICEJET
INDIGO AIR
ChennaiSpiceJet
Air India
ColumbusETIHAD AIRWAYS

Required Data:

OriginDestinationAirline
BangaloreCalicutSpicejet
Indigo Air
ChennaiSpiceJet
Air India
1 Solution

Accepted Solutions
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Try a calculated dimension as a replacement for Destination: =If(aggr(Count(Distinct Airline),Destination)>1,Destination)

Or change your chart expressions. For example sum(Amount) would become sum({<Destination={"=count(distinct Airline)>1"}>}Amount)


talk is cheap, supply exceeds demand

View solution in original post

3 Replies
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Try a calculated dimension as a replacement for Destination: =If(aggr(Count(Distinct Airline),Destination)>1,Destination)

Or change your chart expressions. For example sum(Amount) would become sum({<Destination={"=count(distinct Airline)>1"}>}Amount)


talk is cheap, supply exceeds demand
asgardd2
Creator III
Creator III

Hello!

I think you need to use aggr() function in dimension. (and turn on option "Suppress When value is Null")

IF(Aggr(Count(Distinct Airline), Destination,Origin) > 1, Destination)

qlikviewforum
Creator II
Creator II

Both the above solution doesn't seems to be working for me. Only the below seems to be working for me.

IF(Aggr(Count(Distinct Airline), Destination,Origin) > 1, Destination)