且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何避免重复的值?

更新时间:2023-01-22 16:58:05

您应该能够按PersonID分组,然后按日期,将字段从详细信息部分移动到日期分组页脚,然后禁止Details,PersonID页眉和页脚和日期标题,以便日期页脚工作作为您的详细信息行。这样做只会为每个PersonID和日期组合显示一行。希望有帮助。

You should be able to group by PersonID and then by Date, move the fields from the details section to the Date group footer and then suppress the Details, PersonID Header and Footer, and Date Header so that the Date Footer works as your details row. Doing this will only show one row for each PersonID and Date combination. Hope that helps.

编辑:
每个组标题和页脚仅对值的每次更改显示一次。因此,在你的例子中,如果你没有压制任何部分,你会有如下所示:

Each group header and footer only displays once for each change of the value. Therefore in your example if you didn't suppress any sections you'd have something like the following:

GH1 - 3100
  GH2 - 22-02-2009
      D - 3100   22-02-2009
      D - 3100   22-02-2009
  GF2 - 22-02-2009
  GH2 - 23-02-2009
      D - 3100   23-02-2009
      D - 3100   23-02-2009
      D - 3100   23-02-2009
      D - 3100   23-02-2009
  GF2 - 23-02-2009
GF1 - 3100
GH1 - 3200
  GH2 - 22-02-2009
      D - 3200   22-02-2009
      D - 3200   22-02-2009
      D - 3200   22-02-2009
      D - 3200   22-02-2009
  GF2 - 22-02-2009
  GH2 - 23-02-2009
      D - 3200   23-02-2009
      D - 3200   23-02-2009
      D - 3200   23-02-2009
      D - 3200   23-02-2009
  GF2 - 23-02-2009
GF1 - 3200


$ b b

因此,如果你隐藏所有的部分,除了GF2部分,你会得到:

Therfore if you hide all of the sections except for the GF2 sections you'd get:

  GF2 - 3100   22-02-2009
  GF2 - 3100   23-02-2009
  GF2 - 3200   22-02-2009
  GF2 - 3200   23-02-2009