Asked by:
Problem in Report Viewer .................

Question
-
User-2130229066 posted
Hi Team,
i have created a Report using Matrix Report Viewer.Sql Table has three columns EmployeeId,Date and AttendanceStatus.
in Matrix report viewer EmployeeId is Row,Date is Column and AttendanceStatus is Deatils.i want to add to extra virtual columns here which will display total absent and total present based on values in AttendanceStatus columnslike A for Absent and P for Present.
format is give below.............
EmpID TotalP TotalA 2/1/2012 2/3/2012 2/16/2012 2/17/2012 2/18/2012 1 A SA A A A 2 SA P P P A 3 L A A P SA 4 P P A P SA 5 P P A P SA 6 P p A P SA Only count Absent and Present don't count SA.
Please help me asap.
Thank You !!!
Regards,
Deepak Rai
Noida
Wednesday, March 21, 2012 4:50 AM
All replies
-
User2105670541 posted
write it like in your count text column value expression:
=SUM(iif(Fields!AttendanceStatus.Value="A",1,0))
Wednesday, March 21, 2012 10:59 AM -
User-2130229066 posted
It is showing like that..............
Employee Attendance Report TP 2/1/2012 2/3/2012 2/16/2012 2/17/2012 1 STL51557 Jaspreet Singh 0 8 A A A A 2 STL51836 Maneesh Rawat 0 P P P 5 0 SA 0 3 STL46744 Karan Singh 0 9 A 0 L 4 STL46740 Rahul Singh 0 P P 0 0 1 5 STL46748 Rachna Arora 0 P P 0 1 6 STL46747 Jyoti Arora 0 P p 4 Thursday, March 22, 2012 11:22 AM -
User2105670541 posted
right click on your column matrix that contain the date, add group total >> then pass this expression
Friday, March 23, 2012 12:01 AM -
User-2130229066 posted
Noe it is counting entire records at a time like showing below.
I want to count employee wise absent and present
3/15/2012 3/16/2012 3/17/2012 4 1 STL51557 Jaspreet Singh A A P P 2 STL51836 Maneesh Rawat P P P P 3 STL46744 Karan Singh A A P P Friday, March 23, 2012 5:02 AM -
User2105670541 posted
did you use the expression in the count field.
SUM(iif(Fields!AttendanceStatus.Value="A",1,0))
Friday, March 23, 2012 5:56 AM -
User-2130229066 posted
I am using Asp.net Report Viewer and i have done all the things u told.
where i should add count either in row group or in column group.
there r only one option showing which is subtotal not like group total.
Can you tell me exat steps to do that.
Thank You !!!
Friday, March 23, 2012 6:17 AM -
User2105670541 posted
right click on the data, and then add total
Friday, March 23, 2012 6:20 AM -
User-2130229066 posted
After that it showing a column right side date column with named total.
I have done already it is showing same that i posted earlier.
where i should add exprssion,on place of title or below that.
Thank You !!!
Friday, March 23, 2012 6:27 AM -
User2105670541 posted
correct in the column's row field post your expression.
Friday, March 23, 2012 6:32 AM -
User-2130229066 posted
Noe it showing this
3/16/2012 3/17/2012 Total 1 STL51557 Jaspreet Singh A P P 2 STL51836 Maneesh Rawat P P P 3 STL46744 Karan Singh A P P Friday, March 23, 2012 6:39 AM -
User-2130229066 posted
Friday, March 23, 2012 6:43 AM -
User2105670541 posted
3/16/2012 3/17/2012 Total 1 STL51557 Jaspreet Singh A P P
Did you write expression SUM(iif(Fields!AttendanceStatus.Value="A",1,0)) here???????????
2 STL51836 Maneesh Rawat P P P 3 STL46744 Karan Singh A P P Friday, March 23, 2012 6:47 AM -
User-2130229066 posted
Yes i have written on that place.
Friday, March 23, 2012 6:49 AM -
User-2130229066 posted
It is exactly like that.....................
Fields!Date.Value Total Fields!EmployeeId.Value Fields!First_name.Value Fields!Last_name.Value First(Fields!Final_Status.Value) SUM(iif(Fields!Final_Status.Value="A",1,0)) Friday, March 23, 2012 6:57 AM -
User2105670541 posted
give me the time till evening, i dont have access to sql and ssrs right now, once i'll reach home will try to find out the solution for u. please manage in between,.
Friday, March 23, 2012 7:11 AM -
User-2130229066 posted
Ok Boss !!!
i m using Sql Data Set and Asp.Net Report Viewer 3.5 not SSRS.
Thankx & Most Welcome !!!!
Friday, March 23, 2012 7:21 AM