Same report with different grouping, sorting and totalling

Meeting place for R&R customers and clients to share tips and ideas. Post your questions, messages or problems here.
Post Reply
Sandi_(Guest)
Posts: 10
Joined: Tue Oct 10, 2017 12:44 pm

Same report with different grouping, sorting and totalling

Post by Sandi_(Guest) » Thu May 31, 2001 2:51 pm

I need to print the same data on different criteries for grouping and sorting. For example, I need totals by workers, by days and by department chiefs. How can I do this with one report? It is a lot to work to create one report for every kind of it. Maybe can I do this with different indexes? I am using version 8.1 and an OCX with CA-VO 2.5.

kfleming
Posts: 5795
Joined: Tue Oct 10, 2017 12:44 pm

=> RE: Same report with different grouping, sorting and totalling

Post by kfleming » Fri Jun 01, 2001 1:21 pm

Can you give me an example of how you want the final output to look?____Kathleen__R&R Support

Sandi_(Guest)
Posts: 10
Joined: Tue Oct 10, 2017 12:44 pm

==> RE: Same report with different grouping, sorting and totalling

Post by Sandi_(Guest) » Fri Jun 01, 2001 2:29 pm

I want to print same data on different levels and different sorting.Report will look like this ( 3 examples): ____1.__Worker 1 100 $__Worker 2 150 $__Worker 3 120 $__Worker 4 130 $__Worker 5 220 $ __------------------__Total 720 $__2.__Chief 1 370 $ Summary of workers 1,2,3__Chief 2 350 $ Summary of workers 4, 5__------------------__Total 720 $__3.__T-shirts 80 $__Trousers 350 $__Skirts 290 $__------------------__Total 720 $__ __Regards,__Sandi__

kfleming
Posts: 5795
Joined: Tue Oct 10, 2017 12:44 pm

===> RE: Same report with different grouping, sorting and totalling

Post by kfleming » Sun Jun 03, 2001 12:38 pm

One way to get this result would be to do a multiple scan report.__You would need to index your current master database with a constant value such as 1.__Then use any table as your master file and set the scope to just the first record from the file. Build a calculated field with the expression 1 and use this calculated field to create a scan relation to the current master table.__You will repeat this relation 2 more times, each with different alias name. You could use worker, chief and product to make it simpler.____Then create a calculated field called SORT1 with expression:__IIF(SCAN(worker),1,IIF(SCAN(chief),2,3))__Make this your first sort and group.__The second calc will be SORT2 with expression:__IIF(SCAN(worker),workerid,IIF(SCAN(chief),chiefid,productid))____These fields will become the first and second sort and group fields for your report.____The actual layout of the report will need some group headers/footers with conditional band lines based on the table you are scanning.____I hope that this is enough direction to get you started.__The doc/help file does have some info on working with multiple scan reports.____Kathleen__R&R Support____

Post Reply