1
votes

Hi I'm using Crystal Report 2008 and my design is like this:

 Report header
 Page Header
 Group Header#1 (group by Customer) 
 Group Header#2 (group by Size) (S, M, L)
 Details
 Group Header#2 (group by Size) (S, M, L)
 Group Header#1 (group by Customer) 

Because I want to get the Value by customer and by size so I put my summary fields in Group Header 2, so I have an output like this:

    Customer          Size          Amount
    ----------------------------------------
    CUS-A             SMALL          23500
    CUS-A             MEDIUM         33000
    CUS-B             SMALL          25500
    CUS-B             LARGE          22500
    CUS-C             SMALL          50500
    CUS-C             MEDIUM         20500
    CUS-C             LARGE          15500

The output is correct, but how can I sort the amount by descending order and the output should be like this:

Customer          Size          Amount
    ----------------------------------------
    CUS-C             SMALL          50500
    CUS-A             MEDIUM         33000
    CUS-B             SMALL          25500
    CUS-A             SMALL          23500
    CUS-B             LARGE          22500
    CUS-C             MEDIUM         20500
    CUS-C             LARGE          15500

Thanks,

1
Did you try sorting report by amount? btlynch.com/storage/… - Hiten004
i already tried the record and group sort expert but still not sort by highest to lowest value. it seems because the value are summarized by Customer and size. - Captain16

1 Answers

1
votes

The first thing you'll want to do is change your report to use a single group instead of two separate groups. Create a new formula that combines both the customer and size and use that instead: {Table.Customer} + ' ' + {Table.Size}

Now, go into the "Group Sort Expert" (under the "Report" menu). In the "For this group sort" drop-down menu, select "All", based on "Sum of {Table.Amount}". (Note that this is assuming the group amount summation is already in your report. If it isn't, you'll need to add it.) Finally, select the "Descending" radio button.