Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: CRX Splitting groups by value question Post Reply Post New Topic
Author Message
jkaris
Newbie
Newbie


Joined: 28 Jan 2011
Online Status: Offline
Posts: 2
Quote jkaris Replybullet Topic: CRX Splitting groups by value question
     Posted: 28 Jan 2011 at 12:20pm
Hello!

I went through some training a few years back (basic and advanced) and had been active in both editing canned reports for our business software (E-Automate) and creating new reports from scratch. I am a coldfusion programmer myself and have a pretty good handle on SQL, but as it has been years since I played with CR, I am at a loss on how to accomplish the task at hand.

Way back when, I created an income statement financial report to pull data from out system and format in a way the the CFO wanted it, versus her trying to piece together data manually. It has worked great since then. However, she now wants to have the data output in a different way, in regards to a few GL accounts and I can't for the life of me seem to figure it out. I have scoured this forum and Google as well as referenced my old manuals (from the training sessions) and am still floundering. So, any help would be greatly appreciated.

What we have, is an income statement that groups by Account Type (filtered and ordered), then by Department, then outputs the Account Number.


However, some of the Account Types have Account Numbers that I would like to break into a separate groupings.

Ideally, we could get our software vendor to allow us to create a few more GL Account Types, which would just filter down to the report, but that doesn't look like it is going to happen any time soon.

So, another way to do it would be to be able to specify a couple new groups in our specified order, where the Account Number is in a certain range. However, you can't do that.










I have tried quite a few things memntioned on this board, but am still grasping for straws.

In a nutshell, I want to take this (redacted) report:



and have it split the revenues group into those with Account Numbers, 40600-40650 into a separate group named "Contract Revenues" and something similar in the COGS section.




So now instead of grouping on
if GLAccounts.AccountTypeID = 9, Group as Revenues,
I would like to do do this:
if GLAccounts.AccountTypeID = 9, AND GLAccounts.AccountNumber <40600 AND GLAccounts.AccountNumber > 40650, Group as Revenues - Non Contract, ELSE Group as Revenues - Contract
and I would like to be able to do similar with the others.

However, I do not know how to get Crystal to do what I want.

Sorry if this seems scattered. Hopefully someone understands what I am trying to do and can help.

Thanks guys!


Edited by jkaris - 28 Jan 2011 at 12:22pm
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4374
Quote lockwelle Replybullet Posted: 01 Feb 2011 at 4:18am
What I usually do is create a formula that will do the splitting, and another for name display, so for the splitting:
if GLAccounts.AccountTypeID = 9 then(
  if GLAccounts.AccountNumber in 40600 to 40605 then
     1
  else
    if GLAccounts.AccountNumber in xxxx to yyyyy then
       2
    else
       3
)
else
  0
 
then I would add another grouping inside of the LAccounts.AccountTypeID and have it use the formula to group on.
 
HTH
IP IP Logged
jkaris
Newbie
Newbie


Joined: 28 Jan 2011
Online Status: Offline
Posts: 2
Quote jkaris Replybullet Posted: 01 Feb 2011 at 9:50am
That seems to have done the trick! Thank you SO MUCH!
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