Solved

mutliple detail sections in a single report

Posted on 2003-10-27
10
494 Views
Last Modified: 2011-10-03
Can we use multiple detail sections in single report.Actaully I have two table where information of each table to be show in seperate detail section.
    so the format of my report should be
1)header section of first table
2)detail section of first table
3)header section of second table
4)detail section of second table
5)column of first table - column of second  table (taken as function) and shown in report

Can any one tell me how to present this information. actually i tried to move header section in between two detail sections using format but iam uanble to . can any one give a solution for it so that it will be so much usefull for me
0
Comment
Question by:satish_kotti
  • 3
  • 3
  • 2
10 Comments
 
LVL 12

Expert Comment

by:DRRYAN3
Comment Utility
You can do this, but only if there is a relation defined between the two tables.  You cannot create a functioning report from two tables which are not related.  Even if you use sub reports, the tables must still be related in some way.

Unless you use sub reports, you may not be able to get the two headers you are trying to show.
0
 
LVL 100

Expert Comment

by:mlmcc
Comment Utility
Yes you can have multiple detail sections.

I would use subreports for each table and put the subreports in separate detail sections.

mlmcc
0
 

Author Comment

by:satish_kotti
Comment Utility
both tables have productid in common which is taken as group item.
actually there is not relation between two tables except both tables have productid as common.
 once a product comes in supermaket a product id is generated if it is new product or else existing product id will be used. this is is to tell about our fuctionality of productid.

the need is to show both the tables information  one in each detail section where sub total inquantity is shown in one group section and in  other group section subtotal of outquantity should be shown

1)incoming details headers in header section
2)incoming details based on particular  productid in first detail section
3)incoming details sub total of in quantity placed in a group footer
4)out going details headers placed  in header section
5)outgoing details based on particular  productid placed in a details section
6)outgoing details sub total of out quantity placed in a group footer
7)balance is difference of sub totals incoming quantity and outgoing quantity

the same should be repeated for all group item based on productid until there are no records  on that productid.
      please give me information  regarding  how to procede with this
0
 

Author Comment

by:satish_kotti
Comment Utility
I tried sub reports but i need to break once group of  records belonging to particular incoming productid  then display subtotal of that productid inquantity then   group of  records belonging to particular outgoing productid(records belonging to same product id displayed in incoming)
then display subtotal of that productid out quantity  then balance which is difference of subtotal of in quantity and subtotals of outquantity.
      the same format to be followed for entire report until there are no productid's in the table


Please help me in this
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 
LVL 12

Expert Comment

by:DRRYAN3
Comment Utility
Now you're talking about groups and sub-groups.  Setup a group on the ProductID, then on the field that tells you whether it is incoming or outgoing.  You may need to use a query or stored procedure to union your two tables together into a single table/view/recordset for the purposes of this report.  You haven't mentioned what db you are using, so it's hard to get too specific.
0
 

Author Comment

by:satish_kotti
Comment Utility
i used stored two stored procedure in sql server with group by productid. actually incoming and outgoing  are two different procedures.the client needs both details to be shown in one report  but seperately one in each detail section.
       both procedures show records based on productid ie  for that product id waht all records are there they will be shown one below another.
     

1)      the details for incoming  are
productid  productname inquantity lotnumber expiration date

i haved inserted a group
there i placed the subtotal of inquantity


   2)   the details for outgoing  are
productid  productname outquantity lotnumber out date

i haved inserted a group
there i placed the subtotal of outquantity

3)i need to place balance which is difference of subtotal of in quantity and out quantity


          for example there is product id (c11 and c12) which i need to show details in following format

1)records pertaining to incoming products belonging to c11
2)subtotal of in quantity belonging to c11
3)records pertaining to outing products belonging to c11
4)subtotal of out quantity belonging to c11
5)Balance  ie difference  between suvbtotals of incoming and outgoing  quantity of c11

6)records pertaining to incoming products belonging to c12
7)subtotal of in quantity belonging to c12
8)records pertaining to outing products belonging to c12
9)subtotal of out quantity belonging to c12
10)Balance  ie difference  between subtotals of incoming and outgoing  quantity of c12

same format to be followed for all the records in both tables for all product id

how i need to proceed for gettintg this task achieved.
if iam not clear plese tell me where am not clear so taht i can make you clear at that point. eagerly waiting for the solution as how soon i can get the solution from u gurus i can deliver it to client.
            i tried using sub reports but iam not able to get the task fullfilled





0
 
LVL 12

Accepted Solution

by:
DRRYAN3 earned 63 total points
Comment Utility
Why don't you create a third stored procedure which performs a UNION on the recordsets returned by the first two stored procedures.  Then, Crystal Reports can work as designed.

You are trying to use two unrelated sets of data.  There is nothing here to tie the two recordsets together.  Unless you introduce a table containing unique product IDs and create left joins to your two stored procedure recordsets (which I don't think you can do in Crystal Reports), you have no parent-child, master-detail relationship to work with.  Crystal Reports does not work well with disconnected, unrelated sets of data.

Can you create a new stored procedure?  If so, add a field to the recordset indicating whether or not the record is IN or OUT.  Create a group on ProductID and a second group on the IN/OUT field and you can total and sub-total all day long.
0
 
LVL 100

Assisted Solution

by:mlmcc
mlmcc earned 62 total points
Comment Utility
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now