Page 1 of 1

Same report with different grouping, sorting and totalling

Posted: Thu May 31, 2001 2:51 pm
by Sandi_(Guest)
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.

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

Posted: Fri Jun 01, 2001 1:21 pm
by kfleming
Can you give me an example of how you want the final output to look?____Kathleen__R&R Support

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

Posted: Fri Jun 01, 2001 2:29 pm
by Sandi_(Guest)
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__

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

Posted: Sun Jun 03, 2001 12:38 pm
by kfleming
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____