Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Grouping Problems... Post Reply Post New Topic
Author Message
krisgarcia1414
Newbie
Newbie


Joined: 13 Jan 2012
Online Status: Offline
Posts: 9
Quote krisgarcia1414 Replybullet Topic: Grouping Problems...
     Posted: 02 Aug 2012 at 8:14am
Is there any way to assign values from a database to multiple groups in a single report?

For example:

IF
{lockedLoanTable.SOURCE} = "WHOLESALE"
Then "WHOLESALE"
else if
{lockedLoanTable.SOURCE} IN["RETAIL","CASHOUT"]
Then "RETAIL"
else if {lockedLoanTable.SOURCE} IN["RETAIL","CASHOUT","WHOLESALE"]
Then "TOTAL"

This was my poor attempt to try and create a "TOTAL" group that would report to the same level as my individual groups from the same field.

Basically, I'm trying to get the report to look like the following:

TOTAL Fallout (Includes all Wholesale and Retail loans)
FNMA15
FNMA30
...
...
...

WHOLESALE Fallout
FNMA15
FNMA30
...
...
...

RETAIL Fallout
FNMA15
FNMA30
...
...
...

Any help would be appreciated. Let me know if you have any questions.
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 02 Aug 2012 at 8:31am
The easy way I can think of to do this is to create a subreport for your total data and keep the main report for your grouped data.
I can think of another way using a command (SQL Select query) that includes a UNION, but whether you'll want to go that route depends on how good your SQl skills are.
 
-Dell
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 02 Aug 2012 at 8:31am
one row will only appear in one group.
you can use subreports to mimic the process
 
 
edit: sorry Hilfy, was typing and did not see your response. Sorry to double answer...


Edited by DBlank - 02 Aug 2012 at 8:32am
IP IP Logged
krisgarcia1414
Newbie
Newbie


Joined: 13 Jan 2012
Online Status: Offline
Posts: 9
Quote krisgarcia1414 Replybullet Posted: 02 Aug 2012 at 9:43am
Yeah... I was trying to avoid sub-reports.

When I use sub-reports, I run into a problem with the "new page after" formula. My report has to report in the above format for TOTAL, PURCHASE, and REFINANCE. So page 1 will use the entire database, and report a total, wholesale, and retail breakdown. Page 2 will have to be the PURCHASE loans of that document only, reporting a total, wholesale, and retail as well. Page 3 will be REFINANCE in the same format.

A problem arises when I use "New page after" to separate every 3 sections in congruence with the "Suppress blank section" formula. New page after always seems to take precedence in this situation.

For example, if the client uploads a file without any PURCHASE loans, the sections will be suppressed, but the fact that the PREVIOUS section (TOTAL page) has a "New page after" formula, a blank page gets printed.

I haven't been using Crystal Reports for too long, so I figure I'm missing something...
IP IP Logged
krisgarcia1414
Newbie
Newbie


Joined: 13 Jan 2012
Online Status: Offline
Posts: 9
Quote krisgarcia1414 Replybullet Posted: 02 Aug 2012 at 9:58am
thanks for the responses by the way :)

Here is an idea of what the report will look like in the end...

p.1
OVERALL DATABASE TOTALS


TOTAL Fallout (Includes all Wholesale and Retail loans)
FNMA15
FNMA30
...
...
...

WHOLESALE Fallout
FNMA15
FNMA30
...
...
...

RETAIL Fallout
FNMA15
FNMA30
...
...
...
*Page Break*

p.2
PURCHASE LOANS ONLY


PURCHASE TOTAL Fallout
FNMA15
FNMA30
...
...
...

PURCHASE WHOLESALE Fallout
FNMA15
FNMA30
...
...
...

PURCHASE RETAIL Fallout
FNMA15
FNMA30
...
...
...
*Page Break*

p.3
REFINANCE LOANS ONLY


REFINANCE TOTAL Fallout
FNMA15
FNMA30
...
...
...

REFINANCE WHOLESALE Fallout
FNMA15
FNMA30
...
...
...

REFINANCE RETAIL Fallout
FNMA15
FNMA30
...
...
...
*END*
IP IP Logged
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