I'm using CR 10 and SQL server.
I have a table with employee information- Employee name, address and EmployeeLeavedays
I want data in this format:
EA EB EC ED EE Total
Jan 1 2 0 0 3 6
Feb 0 0 0 0 0 0
Mar 0 0 1 1 0 2
Apr 0 0 0 0 0 0
May 1 1 1 1 1 5
Jun 0 1 2 1 0 4
Jul 0 0 0 0 1 1
Aug 0 3 0 3 1 7
Sep 0 0 0 0 0 0
Oct 2 2 1 2 1 8
Nov 0 5 4 0 0 9
Dec 2 2 1 1 2 8
Above crosstab would help to know the number of leave of absence for each employee in each month.
I tried to use in-built crosstab functionality and since no one took any leave in the months of Feb, Apr and Sep CR is deleting the 3 rows entirely and displayng the remaining rows.
I want to show all the months even though there is no data for those months.
Could anyone help me with this?
Thanks in advance.
I have a table with employee information- Employee name, address and EmployeeLeavedays
I want data in this format:
EA EB EC ED EE Total
Jan 1 2 0 0 3 6
Feb 0 0 0 0 0 0
Mar 0 0 1 1 0 2
Apr 0 0 0 0 0 0
May 1 1 1 1 1 5
Jun 0 1 2 1 0 4
Jul 0 0 0 0 1 1
Aug 0 3 0 3 1 7
Sep 0 0 0 0 0 0
Oct 2 2 1 2 1 8
Nov 0 5 4 0 0 9
Dec 2 2 1 1 2 8
Above crosstab would help to know the number of leave of absence for each employee in each month.
I tried to use in-built crosstab functionality and since no one took any leave in the months of Feb, Apr and Sep CR is deleting the 3 rows entirely and displayng the remaining rows.
I want to show all the months even though there is no data for those months.
Could anyone help me with this?
Thanks in advance.