Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Analysis Server and Reporting Services (2008)
 Rounding

Author  Topic 

nikoo56
Starting Member

26 Posts

Posted - 2012-03-19 : 12:57:16
I have this expression in my report:

=floor(Avg(Fields!final_rep_response1.Value)/60) & ":" & Avg(Fields!final_rep_response1.Value) mod 60



It return as for example: 19:30.400000000001

I like to return as 19:30.

sunitabeck
Master Smack Fu Yak Hacker

5155 Posts

Posted - 2012-03-19 : 13:05:21
[code]=floor(Avg(Fields!final_rep_response1.Value)/60) & ":" & Round(Avg(Fields!final_rep_response1.Value) mod 60)[/code]Use Fix function if you want to truncate rather than round.
Go to Top of Page

nikoo56
Starting Member

26 Posts

Posted - 2012-03-19 : 13:28:39
Thanks it worked.

quote:
Originally posted by sunitabeck

=floor(Avg(Fields!final_rep_response1.Value)/60) & ":" & Round(Avg(Fields!final_rep_response1.Value) mod 60)
Use Fix function if you want to truncate rather than round.

Go to Top of Page
   

- Advertisement -