Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Firstsortedvalue returns Null

Hi everybody, I have the following expression:

FirstSortedValue(DescriptionFixed,Aggr(sum(Amount-OriginalAmt), DescriptionFixed))

Since I have exactly the same amount for two different items the firstsortedvalue brings me NULL.

How can I get just one item instead of NULL?  Either item will work.

Any help will be greatly appreciate it

14 Replies
Not applicable
Author

Sorry Eric. I don't know how to help in this case...but this is a community, there are always people who understand some issues better than others.

Not applicable
Author

Don't worry thank you very much.

Have a great day!

IAMDV
Luminary Alumni
Luminary Alumni

Hi Eric,

Are you still looking for the solution? I realise that it's 2 weeks old thread.

If yes, so you don't mind getting either value when there's clash?

Cheers,

DV

www.QlikShare.com

Not applicable
Author

Hi Deepak, thanks for the following up, the first question has been answered, but I am struggling on the second one, any advice?

I just created a backorder app:

Our ideal billing process is for every Cust PO  one invoice is created, however that is not happening and my App is showing unreal BO.

Example:

CustPO: 0029075 is related with 2 invoices: SI015361 and SI015362. This causes that the report show unreal BO, for example the first LineNo_"200000" on the report has $1,706 on PO Amount, but 0 invoiced, meaning that the line is consider as a BO, however the second row same item and same LineNo_"200000" show $1,706 on PO Amount and $1,706 invoiced. Hence the first line it is not a BO.

Thanks for your help.

Valentino_Rossi_46
Contributor II
Contributor II

Hola Nuno me podrías ayudar

 

No quiero nulos ni vacíos 

= FirstSortedValue(Cliente,Aggr(sum(if(Televisora='TVMAS' and Año='2019',Value))/SUM(IF(Año='2019',Value)),Cliente))

 

Saludos!!!