使用公式字段摘要为组记录创建组摘要和总计摘要 [英] Create group summary and Grand Total Summary for group records with formula field summary

查看:86
本文介绍了使用公式字段摘要为组记录创建组摘要和总计摘要的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从名为"Product_Order"的表中创建了一个报表,其中包含以下字段

I created a report from a table named "Product_Order" with the following fields

secret_code
mem_name
mem_code
mem_chapter
trn_date
ar_no
or_no
pro_category
pro_sub_category
pro_code
pro_name
pro_qty
pro_cost
pro_price
total_cost
total_price
pay_mode
pay_terms
process_by
deliver_by





现在我需要显示基于组的报告

注意:RC =报告列

第1组-Pro_Category:具有字段"Pro_Category"
组2-Pro_Name:在下面具有以下字段

RC 1-字段:pro_sub_category
RC 2-字段:pro_code
RC 3-字段:pro_name
RC 4-公式字段:sum({product_order.pro_qty},{product_order.pro_name})
RC 5-字段:pro_cost
RC 6-字段:pro_price
RC 7-公式字段:{product_order.pro_price}-{product_order.pro_cost}
RC 8-公式字段:{product_order.pro_cost} *总和({product_order.pro_qty},{product_order.pro_name})
RC 9-公式字段:{product_order.pro_price} *总和({product_order.pro_qty},{product_order.pro_name})
RC 10-公式字段:RC9-RC8

我无法执行的任务:
总结RC8,RC9和基于组1的RC10-Pro_Category.
汇总所有RC8,RC9和RC10-像汇总摘要一样"

简而言之,我需要总结一个摘要字段.


您可以在以下位置查看和下载数据库文件和屏幕截图:
< ahref> https://dl.dropbox.com/u/65392916/SAMPLE.zip [ ^ ]

希望这足够清楚以至于可以理解.





Now i needed to show report based on a group

NOTE: RC = REPORT COLUMN

Group 1 - Pro_Category: Has field "Pro_Category"
Group 2 - Pro_Name: Has the following fields below

RC 1 - Field: pro_sub_category
RC 2 - Field: pro_code
RC 3 - Field: pro_name
RC 4 - Formula Field: sum({product_order.pro_qty},{product_order.pro_name})
RC 5 - Field: pro_cost
RC 6 - Field: pro_price
RC 7 - Formula Field: {product_order.pro_price}-{product_order.pro_cost}
RC 8 - Formula Field: {product_order.pro_cost} * Sum ({product_order.pro_qty}, {product_order.pro_name})
RC 9 - Formula Field: {product_order.pro_price}*Sum ({product_order.pro_qty}, {product_order.pro_name})
RC 10 - Formula Field: RC9 - RC8

Task i can''t do:
Summarize RC8, RC9 & RC10 based on Group 1 - Pro_Category.
Summarize ALL RC8, RC9 & RC10 - "Like a GRAND TOTAL SUMMARY"

In short i needed to summarize a summarized field.


You may see and download database file and screen shot at:
<ahref>https://dl.dropbox.com/u/65392916/SAMPLE.zip[^]

Hope this is clear enough to understand.

推荐答案


经过多次尝试,我设法找到了可以回答我问题的文章.

@reset
在打印记录时;

全局数字var GTotal:= 0;
//将此内容放置在报告标题中,或将其放在较高的grou标题中(
)
@Eval

在打印记录时;

全局数字var GTotal:= GTotal + Sum(valuefield,groupfield);
//将其放在您的总和显示的组页脚中

@display
在打印记录时;

全局数字var GTotal;
//将此放置在报表或更高级别的页脚中
After many attempts i managed to find an article that answers my question.

@reset
whileprintingrecords;

global numbervar GTotal:=0;
//place this in report header, or higher grou header as appropriate

@Eval

whileprintingrecords;

global numbervar GTotal:=GTotal + Sum( valuefield, groupfield);
// place this in group footer where your sum shows

@display
whileprintingrecords;

global numbervar GTotal;
//Place this in report or higher group footer


这篇关于使用公式字段摘要为组记录创建组摘要和总计摘要的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆