0

Top customer ranking issue

I am using jet 2009 and Nav 5.1. I read other posts on sorting by sum and created this formula which is working fine except it is duplicating the rows for ranking. I have attached the sample output.
Here is my NL function:
=NL("rows","Cust. Ledger Entry","Customer No.","-=NL(""sum"",""Cust. Ledger Entry"",""Amount ($)"",""Customer No."",NF(,""Customer No.""),""Posting Date"","""&$E$6&""",""Document Type"","""&$E$7&""",""Global Dimension 1 Code"","""&$E$8&""",""Global Dimension 2 Code"","""&$E$9&""")","*","Posting Date",$E$6,"Limit=",$E$5)

I wanted top 5 customers by sales in desceding value. It gives me repeat rows (25) for these five customers.
Cell E5 formula is: =IF(ISNUMBER(Options!D4),Options!D4,5)


Rank cell formula is: =NL("Rows","Integer","Number","Number","1.."&$E$5)
Can any one please help me fix the problem that causing this issue.

2 comments

Please sign in to leave a comment.