Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Grouping on part of a field

Status
Not open for further replies.

ginaburg

Technical User
Jul 14, 2004
62
US
I am using Crystal 8.5.
I have a field called PACOSTCATID.
I want to group on part of that field as shown below.
PACOSTCATID
0100000010 this is used for budget $
0100000011 this is used for actual $
0100000012 this is used for actual $
0100000020 this is used for budget $
0100000021 this is used for actual $
0100000022 this is used for actual $

I want to group on the first 9 characters. For the above expample, I would have 2 groups 010000001 and 010000002.
I tried to put a formula on the group for
Left ({PA01301.PACOSTCATID}, 9)

In my report, I have a column for budget and one for actual. When I use this grouping, I get the following:

010000001 group heading
0100000010 50,000 budget amount

010000001 group heading
0100000011 1000 acutal amount
0100000011 1000 actual amount

how do I get one group heading with everyhting under it.

 
Are you using other groupings?

Your formula looks fine, so you're probably leaving out important information, such as the fact that you have some other grouping.

BTW, I'd use:

val(Left({PA01301.PACOSTCATID}, 9))

-k
 
Looks like you have PACOSTCATID as group 1 and your formula as group 2. If this is so, reverse them.

MrBill
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top