Solved

Create report Group based on Formula Field

Posted on 2009-04-12
4
743 Views
Last Modified: 2012-05-06
While this question: http://www.experts-exchange.com/Database/Reporting_/Crystal_Reports/Q_23247486.html implies that it should be no problem to create a group based on a Formula Field, I'm unable to do so. I've created a Formula Field but can't find it in the list of fields available in the Group Expert.

The problem I'm trying to resolve is as follows:
- The company record includes an Industry Code
- I want to group all of the company records in my report based on the Industry Code Category.
- The industry code may be NAICS or may be SIC
- NAICS and SIC codes/descriptions/categories are stored in separate tables
- I must check each company record at runtime to determine whether it is an NAICS or SIC code

My approach, so far, was to create a formula field named Industry Category that tests the code and determines whether it is NAICS or SIC and then returns the associated Category (a string). I then wanted to add a group to my report based on Industry Category, but I can't find that field in the Group Expert.

Do I need to do something special to have the Formula Field available in the Group expert?
0
Comment
Question by:PolicyWorks
  • 2
4 Comments
 
LVL 16

Expert Comment

by:wykabryan
ID: 24130420
Certain formulas you can not group on. Please provide the code that you are using in this formula.
0
 
LVL 34

Accepted Solution

by:
James0628 earned 500 total points
ID: 24134411
As he said, there are some limits.  For example, the formula must reference a field in your record (it sounds like you're doing that), and it can not use any CR summary functions.  If you post your formula, we can take a look at it.

 James
0
 
LVL 1

Author Closing Comment

by:PolicyWorks
ID: 31569403
@James0628: Thanks, I wasn't referencing a field in my report, I was (for reasons I'm not sure of) referencing a different formula field (unnecessarily). I fixed up my formula and it work now. Stay tuned, I'll be adding another question that's a bit more complex (at least, it's complex to explain...we'll see if it's complex to resolve).
0
 
LVL 34

Expert Comment

by:James0628
ID: 24134669
Ah.  Well, there you go.  :-)

 You're welcome.  Glad I could help.

 James
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

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. …
I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

821 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