Thursday, August 13, 2009

Master Detail Group Report Using Crystal Report XI



Report generation Plays a Major Role in Application Project, So I will show you how create a simple report using Crystal Report XI


Say Table A --> Describes the student Details


Table A
Student Id (Primary Key)
Student Name
Student Class




Say Table B --> Describes the Student Fees Paid Details


Table B
Paid Id (Primary Key)
Student Id (Foreign Key)
Paid Amount
Paid Date

Table B will have multiple Entries for Single Entry of Table A


I will Explain Step by Step Method to display in the Crystal Report XI


Step 1: Open Crystal Report XI
Step 2: File-> New-> Standard Report
Step 3: Create New Connection-> OLE DB (ADO) -> Microsoft OLE DB Provider for Oracle
I have mentioned for Oracle Provider, you can select your own data source
Step 4: Service: Server Name; UserId: Username; Password: Password of the server
Step 5: Select the Two Tables from Left Side Pan of Available Data source and Move to Right Side
Step 6: Click Next
Step 7: You will see two tables in the Report Creation Wizard, Now Select the Primary Key of Table A and Drag to Table B’s Foreign Key
Step 8: Select the Line/Link of the two tables and Right Click it Select Link Option
Step 9: Select the Radio Button of Left Outer Join and Press Ok button
Step 10: Click Finish Button
Step 11: Select from Menu Insert-> Group Select the Primary Key of Table A and Select Ascending Order and Press Ok Button
Now you can see Detail Section below Group Section
Step 12: Now place the Table A Details in Group Header Section and Place the Table B Details in Details Section



If you preview, you can see the Table B Details of Every Record of Table A
And you can filter by record selection formula.



Happy To Share!




No comments:

Post a Comment