Crystal Reports:构建复杂的记录选择



我负责开发一个库存快照报告,该报告分为两种类型:订单和库存。除此之外,只有具有特定状态的项目才应显示在报告中。

I have a parameter that is used to determine the specific date for the report. {?endDate}
I have a field in a view that pulls the date the item was received. {rec_date}
I have a formula field that pulls the group (orders/stock) -- {@grouping}
I have a formula field that pulls the status -- {@state}

本质上,我在记录选择中需要的是:

( @grouping = "Orders" and rec_date < {?endDate} and @state in (0,2,5) )
OR
( @grouping = "Stock" and rec_date < {?endDate} and @state in (1,2,3,5,7) )

我试图写这篇文章的任何方式都是无效的。如有任何帮助,我们将不胜感激。

您的公式也必须在波浪形括号中:

( {@grouping} = "Orders" and rec_date < {?endDate} and {@state} in [0,2,5] )
OR
( {@grouping} = "Stock" and rec_date < {?endDate} and {@state} in [1,2,3,5,7] )

相关内容

  • 没有找到相关文章

最新更新