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

Using firstsortedvalue

Hi,

I am using firstsorted value in a textbox.

When I do:

=FirstSortedValue(producto, -aggr(sum(venta),producto))

it works and I get the value P2 , now I want to know the sales of product P2:

=sum( { <producto={P2}> } venta )

But when I use that expresion:

=sum( { <producto={( =FirstSortedValue(producto, -aggr(sum(venta),producto)))}> } venta )

It doesn't work....

I don't know what is wrong, can anybody help me?

Thanks,

1 Solution

Accepted Solutions
sunny_talwar

Try it like this:

=sum({<producto = {"$(=FirstSortedValue(producto, -aggr(sum(venta),producto)))"}>} venta)

View solution in original post

1 Reply
sunny_talwar

Try it like this:

=sum({<producto = {"$(=FirstSortedValue(producto, -aggr(sum(venta),producto)))"}>} venta)