How to take only certain columns from a FILTER result?

前端 未结 1 1877
迷失自我
迷失自我 2021-02-05 01:53

I\'m using FILTER to extract rows from a range, and want to take only certain columns. For example, I filter by D, but want only columns B,C in reverse order. I tri

1条回答
  •  借酒劲吻你
    2021-02-05 02:38

    When you are QUERYing a computed array, you need to use the Colx notation rather than column letters:

    =QUERY(FILTER(B:D,D:D>=2),"select Col2, Col1")

    which incidentally can be achieved by just using the QUERY:

    =QUERY(B:D,"select C, B where D >= 2")

    or just FILTER:

    =FILTER({C:C,B:B},D:D>=2)

    0 讨论(0)
提交回复
热议问题