Quantcast
Channel: SQL Server Reporting Services, Power View forum
Viewing all articles
Browse latest Browse all 28687

Count in Expression ReportViewer

$
0
0

Hello guys, I have a doubt. I have an expression that I have to add up a column and divide the sum by the number of lines, however, I have great difficulties and have to deliver my project for tomorrow. Please help me!

The problem is that the account he should skip the "0", any way to skip the number zero, otherwise it will divide by values ​​that do not exist. So I had to skip all the zero in the Count



The expression:

= FormatNumber (IIf(Fields!Auditado.Value  > Fields!Reducao.Value,  SUM( Fields!Auditado.Value / IIF (Fields!Itens.Value <= 0, 1, Fields!Itens.Value)), IIf (Fields!Reducao.Value > Fields!Vendas.Value, sum (Fields!Reducao.Value / IIF (Fields!Itens.Value <= 0, 1, Fields!Itens.Value)),SUM (Fields!Vendas.Value/ IIF (Fields!Itens.Value <= 0, 1, Fields!Itens.Value)))))/Count (IIf (Fields!Auditado.Value  > Fields!Reducao.Value,   ( Fields!Auditado.Value / IIF (Fields!Itens.Value <= 0, 1, Fields!Itens.Value)), IIf (Fields!Reducao.Value > Fields!Vendas.Value,  (Fields!Reducao.Value / IIF (Fields!Itens.Value <= 0, 1, Fields!Itens.Value) ), Fields!Vendas.Value / IIF (Fields!Itens.Value <= 0, 1, Fields!Itens.Value))))


Assunto = dúvida



Viewing all articles
Browse latest Browse all 28687

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>