Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
cmccafferty
Contributor III
Contributor III

Return values "where" condition is true

Hi,

I am trying to get Single Prices and Twin Prices into seperate boxes. Very simple. Just a box that shows the amount.

So, at the minute I have these:

='Single Selling Price : ' & num(max ([Cost PP]), '£#,##0', '.' , ',' )

I have another table [PriceTypeDescription] that shows me the price for a single and the price for a twin. I was wondering how I can do a statement in my above formula that sort of says:

='Single Selling Price : ' & num(max ([Cost PP] where [PriceTypeDescription] = 'Single' ), '£#,##0', '.' , ',' )  so that I only get returned the single price.

Many thanks in advance

Chris

1 Solution

Accepted Solutions
Not applicable

Hi ,

       Try the below code

='Single Selling Price : ' & num(max ( { <[PriceTypeDescription] ={'Single'}> } [Cost PP] ), '£#,##0', '.' , ',' )

//Yusuf

View solution in original post

7 Replies
Not applicable

Hi ,

       Try the below code

='Single Selling Price : ' & num(max ( { <[PriceTypeDescription] ={'Single'}> } [Cost PP] ), '£#,##0', '.' , ',' )

//Yusuf

cmccafferty
Contributor III
Contributor III
Author

Sorry to bother again.. but can more than one criteria be applied? So that it works a bit like SUMIFS on Excel.

So for example:

='Single Selling Price : ' & num(max ([Cost PP] where [PriceTypeDescription] = 'Single', and [Ticket Category] = 'First Class', and [Airline] = 'Qantas' ), '£#,##0', '.' , ',' )  so that I only get returned the single price.

Many thanks

Chris

cmccafferty
Contributor III
Contributor III
Author

Sorry to bother again.. but can more than one criteria be applied? So that it works a bit like SUMIFS on Excel.

So for example:

='Single Selling Price : ' & num(max ([Cost PP] where [PriceTypeDescription] = 'Single', and [Ticket Category] = 'First Class', and [Airline] = 'Qantas' ), '£#,##0', '.' , ',' )  so that I only get returned the single price.

Many thanks

Chris

cmccafferty
Contributor III
Contributor III
Author

Sorry to bother again.. but can more than one criteria be applied? So that it works a bit like SUMIFS on Excel.

So for example:

='Single Selling Price : ' & num(max ([Cost PP] where [PriceTypeDescription] = 'Single', and [Ticket Category] = 'First Class', and [Airline] = 'Qantas' ), '£#,##0', '.' , ',' )  so that I only get returned the single price.

Many thanks

Chris

Not applicable

HI ,

      Yes , we can apply more than one criteria .

Try  the below code .

='Single Selling Price : ' & num(max ( { <[PriceTypeDescription] ={'Single'} , [Ticket Category] = {'First Class'} , [Airline] ={ 'Qantas' } > } [Cost PP] ), '£#,##0', '.' , ',' )

Thanks & Regards

Yusuf Ali

Not applicable

HI ,

     Yes , we can apply more than one criteria .

Try  the below code .

='Single Selling Price : ' & num(max ( { <[PriceTypeDescription] ={'Single'} , [Ticket Category] = {'First Class'} , [Airline] ={ 'Qantas' } > } [Cost PP] ), '£#,##0', '.' , ',' )

Thanks & Regards

Yusuf Ali

Not applicable

HI ,

     Yes , we can apply more than one criteria .

Try  the below code .

='Single Selling Price : ' & num(max ( { <[PriceTypeDescription] ={'Single'} , [Ticket Category] = {'First Class'} , [Airline] ={ 'Qantas' } > } [Cost PP] ), '£#,##0', '.' , ',' )

Thanks & Regards

Yusuf Ali