Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report generation using 2 Tables with out Join condition

Status
Not open for further replies.

Manishreya

Programmer
Dec 27, 2000
14
US
I am using Crystal reports 8 version

I have to create a report which is calling 2 tables and data to be used from 2 tables independently.
I have to use fields from 2 tables and there is a field to supply from selection formula which is the Filter.

If I join 2 tables the data can not be accurate.

In Detail 1st table i need to use summary of quotatotal field which is calculating Summary of that field matching the field Year.

From 2 table I have list of Students enrolled for that perticular Year from that I need to collect No of Students.

Problem is independent data from 2 tables to be displayed in Single report..

There is a any way to genarate report using Code?

Help is requested.

Thanks
 
Manishreya: Your post was I think titled incorrectly - I assume you mean you are trying to write reports on 2 tables without join relationships. The classic way of doing this in Crystal is to write one report against 1 table and include this as a subreport in a main report written against the other (e.g. the one with the summary).

If you group the main report by year (creating a Group Header and Footer) you can then insert the subreport on either and link by the use of a formula field in each report which calculates the year to the same type and format. This will then enable you to create a listing of all students in the subreport and have the summary total produced in the main.

Any more needed drop me a line
David C. Monks
david.monks@chase-international.com
Accredited Seagate Enterprise Partner
 
Thanks,

I need to disply in a single page I dont have a option for Sub Report

 
Manishreya: You can still display in a single page as you could use the ability to share variables between a main and subreport to transfer the summary total if you prefer (i.e. do it the other way around)

Drop me a line if you need any more David C. Monks
david.monks@chase-international.com
Accredited Seagate Enterprise Partner
 
You will be stuck without subreports.

A Crystal report can only be based on one SQL results table. While a results table can be drawn from many joined tables, it cannot incluce data from tables that are not joined to the results.

You can have subreports on the same page. Are you using an older version that doesn't support subreports? Ken Hamady
Crystal Reports Training and a
Quick Reference Guide to VB/Crystal
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top