Group in Crystal report

I want  sum of QuantityPerPallets,Pallets,NetWeight,GrossWeight according to group by  ContainerNo , Departmentseal, LinesealNo wise in crystal report .I have attached the table script.


Table Script : PackingLIST_SQL.txt
Payal sathavaraWindows Developer Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Raghavendra HullurSoftware DeveloperCommented:
Hi,

You can do it at the SQL level itself by grouping on the fields you mentioned, something like below with any additional filter conditions if you have:

select ContainerNo_2166 , Departmentseal_2166, LinesealNo_2166, sum(QuantityPerPallets_2166) sum_QuantityPerPallets_2166, sum(Pallets_2166) sum_Pallets_2166, sum(NetWeight_2166) sum_NetWeight_2166, sum(GrossWeight_2166) sum_GrossWeight_2166
from packingList
group by ContainerNo_2166 , Departmentseal_2166, LinesealNo_2166;


Or if you want to do it at Crystal level, then simply insert groupings on ContainerNo_2166 , Departmentseal_2166, LinesealNo_2166 and then insert summaries for QuantityPerPallets,Pallets,NetWeight and GrossWeight and display the fileds and summaries in group header 3.

This is what I got when ran above query:

PackingList.JPG
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Crystal Reports

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.