How to select a named range in Google Sheets' query?

北战南征 提交于 2021-02-08 06:49:56

问题


I'm trying to set up a query using named ranges, is it possible to select a named range within a query?

I've tried the following:

=QUERY(NamedRange, "select '"&NamedRange2&"' where '"&NamedRange3&"' contains '"&B2&"' ")

I want to be able to use named ranges instead of having to use select A where...or select col1 where... since the spreadsheet is constantly going through revisions where columns change so I want to keep the query dynamic so it doesn't constantly need updating.


回答1:


partially. you can have it like this:

=QUERY({NamedRange}, "select Col1 where Col1 contains '"&B2&"'")


来源:https://stackoverflow.com/questions/56077747/how-to-select-a-named-range-in-google-sheets-query

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!