Click here to Skip to main content
15,885,366 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I am trying to design a report in crystal reports. I am fetching data from following table.

Id int,
CompanyName varchar,
NoOfEmployees int,
DeptId int,
Status char


Now I want to display Department wise number of employee for each company.

The report should display something like below

            Admin        Sales         Development       Support
Company 1      5            12                  22            15
Company 2      4             9                  35            19
Company 3      5            13                  29            10


Using sql query I have retrieved the result as follows

SQL
Company 1  Admin         5
Company 1  Sales        12
Company 1  Developement 22
Company 1  Support      15


and so on.


Now how can I display the above result as per required format?
Posted

1 solution

You can use Crystal Report Cross Tab for designing such reports.
Following link may be resourceful for you.

Understanding Crystal Cross Tabs – Part 1[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900