Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: How can I do the following reports? Post Reply Post New Topic
Author Message
jonathanang
Newbie
Newbie


Joined: 22 Jul 2016
Location: Singapore
Online Status: Offline
Posts: 3
Quote jonathanang Replybullet Topic: How can I do the following reports?
    Posted: 27 Jul 2016 at 5:24am
Please refer to the attachment at, http://www.j2000.com.sg/wp-content/uploads/2016/07/report1.png

The users requested 2 kinds of report and I thought of using subreport to fulfill the request.

I have 3 tables in my database.

SalesInvoice is a one-to-many relationship to SalesInvoiceDetail table (linking field is ‘InvoiceId’ column in both tables).
SalesInvoiceDetail has a column named ‘article_size’ which is a one-to-many relationship to ArticleSize table (linking field is ‘SizeId’ column in both tables.

Basically the subreport is showing the different sizes (these sizes are not limited to S, M, L) and it varies to unlimited type of sizes.

So how do I achieve the above 2 reports?
IP IP Logged
kevlray
Admin Group
Admin Group
Avatar

Joined: 29 Oct 2009
Online Status: Offline
Posts: 1587
Quote kevlray Replybullet Posted: 27 Jul 2016 at 7:19am
I got a connection refused when trying to open the image.  Since I cannot see the image.  Can you explain why you think you need a sub-report?
IP IP Logged
jonathanang
Newbie
Newbie


Joined: 22 Jul 2016
Location: Singapore
Online Status: Offline
Posts: 3
Quote jonathanang Replybullet Posted: 27 Jul 2016 at 8:24pm
Originally posted by kevlray

I got a connection refused when trying to open the image.  Since I cannot see the image.  Can you explain why you think you need a sub-report?


IP IP Logged
jonathanang
Newbie
Newbie


Joined: 22 Jul 2016
Location: Singapore
Online Status: Offline
Posts: 3
Quote jonathanang Replybullet Posted: 27 Jul 2016 at 8:25pm
I am not sure if I need to use a subreport though since I am aware that subreport affects performance.

For Report Format 1, the subreport simply displays the quantity for certain size type and it has no unit price.

For Report Format 2, the subreport has both the size type, quantity and a unit cost for each row. I need to get the total for each of its own subreport.

Edited by jonathanang - 27 Jul 2016 at 8:27pm
IP IP Logged
kevlray
Admin Group
Admin Group
Avatar

Joined: 29 Oct 2009
Online Status: Offline
Posts: 1587
Quote kevlray Replybullet Posted: 28 Jul 2016 at 4:17am
I am not sure how you have the main report formatted.  But I think the quantity for a certain size would just be a running total.  Again I think the second sub-report  could be a running total.  Another thought (depending of your SQL skills).  You may be able create sub-queries to return the totals that you need.
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.000 seconds.