在summig数字列时,如何在电子表格中合并重复行?

发布于 2025-02-05 12:24:54 字数 376 浏览 2 评论 0原文

我的项目报告来自两种不同的来源,因为我们在今年中年更改了项目管理工具。因此,我已经在Google电子表格中准备了两个选项卡,并在同一组标题下使用了两个系统的数据。然后,我使用以下查询将这两张纸合并为一张,

=QUERY({'Sheet1'!A1:I1000;'Sheet2'!A2:I1000},"select * where Col1 <>''")

我的一些项目都在列表中,因为它们是在年初开始的。为了避免重复,我需要将代表同一项目的两个行合并为一个。项目名称是相同的。但是,我需要获得一些列的总和,例如为了接收整个期间的总价值。同时,诸如“项目所有者”之类的列在两行之间是相同的。 在合并Selcted列时,如何将这些重复的行组合为单行? 预先感谢您的支持!

My Project Reports come from two different sources as we have changed the Project Management tool middle of the year. Therefore, I have prepared two tabs within a Google Spreadsheet with the data from the two systems under same set of headings. Then I combined the two sheets into one using the following query,

=QUERY({'Sheet1'!A1:I1000;'Sheet2'!A2:I1000},"select * where Col1 <>''")

Some of my projects are present within the both the list as they were started early in the year. In order to avoid duplicates I need to merge the two rows representing the same project into one. The project names are identical. However, I need to get the sum of some of the columns such as the 'Time Spent' in order to receive the total value for the whole period. At the same time, columns such as ' Project Owner' are identical among the two rows.
How can I combine these duplicate rows into single rows while merging the selcted columns?
Thank you in advance for your support!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

反差帅 2025-02-12 12:24:54

语法为:

=QUERY({Sheet1!A1:B; Sheet2!A2:B}, 
 "select Col1,sum(Col2)
  where Col1 is not null 
  group by Col1 
  label sum(Col2)''")

列是文本,b列是数字值

syntax is:

=QUERY({Sheet1!A1:B; Sheet2!A2:B}, 
 "select Col1,sum(Col2)
  where Col1 is not null 
  group by Col1 
  label sum(Col2)''")

where A column is text and B column are numeric values

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文