gpt4 book ai didi

google-sheets - 如何在 Google 表格中转置此数据

转载 作者:行者123 更新时间:2023-12-03 08:51:02 24 4
gpt4 key购买 nike

我在谷歌工作表中有数据,我只想在我的其他工作表中获取该数据,但以转置方式这是例如:

Column A    | Column B    | Column C
=================================
site1.com | Name 1 | Name 2
site2.com | Name 3 | Name 4
site3.com | Name 5 | Name 6

想要这样的数据

Column A    | Column B    | Column C
=================================
site1.com | site2.com | site3.com
Name 1 | Name 3 | Name 5
Name 2 | Name 4 | Name 6

我不想在每一行中手动输入公式,所以 arryformula 可以自动执行此操作。

我正在尝试这个,但无法达到我想要的效果。

=ARRAYFORMULA(TRANSPOSE(Sheet1!$B2:B300 & Sheet1!$L2:L300))

最佳答案

尝试:

=ARRAYFORMULA({TRANSPOSE(SORT(FILTER(A:A, A:A<>""))); 
SUBSTITUTE(TRANSPOSE(SPLIT(TRANSPOSE(QUERY(TRANSPOSE(
IF(ISNUMBER(QUERY(QUERY({A:B; A:A, C:C},
"select count(Col1) where Col1 is not null group by Col1 pivot Col2"),
"offset 1", 0)), SUBSTITUTE(QUERY(QUERY({A:B; A:A, C:C},
"select count(Col1) where Col1 is not null group by Col1 pivot Col2"),
"limit 0"), " ", "♦"), )),,999^99)), " ")), "♦" , " ")})

0

关于google-sheets - 如何在 Google 表格中转置此数据,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58972824/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com