为什么这个具有多个条件的 ARRAYFORMULA + VLOOKUP() + REGEXEXTRACT() 不起作用?

问题描述 投票:0回答:1

在一张纸中,我有公共图像,其链接如下

https://drive.google.com/file/d/1-gnl6ODS5sinOPsd0fcvszbA-bduNE2I/view?usp=sharing
结果应该是:
https://drive.google.com/uc?export=view&id=1-gnl6ODS5sinOPsd0fcvszbA-bduNE2I

所以,我正在研究这个公式,以获得预期的收益:

https://drive.google.com/uc?export=view&id=1-gnl6ODS5sinOPsd0fcvszbA-bduNE2I

公式:

=ARRAYFORMULA(IF(A3:A="",,Image("https://drive.google.com/uc?export=view&id="&regexextract(VLOOKUP($J$3:$J&" "&$N1:$N$1,
 QUERY({
 IMPORTRANGE("1gh5w0czg2JuoA3i5wPu8_eOpC4Q4TXIRhmUrg53nKMU","Image Link!A1:A")&" "&
 IMPORTRANGE("1gh5w0czg2JuoA3i5wPu8_eOpC4Q4TXIRhmUrg53nKMU","Image Link!C1:C"),
 IMPORTRANGE("1gh5w0czg2JuoA3i5wPu8_eOpC4Q4TXIRhmUrg53nKMU","Image Link!F1:F")}, 
 "select Col1,Col3"), 2, 0)),"d/(.+)/view")))

这是文件,以防您想尝试一下。

google-sheets google-sheets-formula
1个回答
1
投票

尝试:

=ARRAYFORMULA(IF(A3:A="",,Image("https://drive.google.com/uc?export=view&id="&regexextract(VLOOKUP($J$3:$J&" "&$N1:$N$1,
 QUERY({
 IMPORTRANGE("1gh5w0czg2JuoA3i5wPu8_eOpC4Q4TXIRhmUrg53nKMU","Image Link!A1:A")&" "&
 IMPORTRANGE("1gh5w0czg2JuoA3i5wPu8_eOpC4Q4TXIRhmUrg53nKMU","Image Link!C1:C"),
 IMPORTRANGE("1gh5w0czg2JuoA3i5wPu8_eOpC4Q4TXIRhmUrg53nKMU","Image Link!F1:F")}, 
 "select Col1,Col2"), 2, 0),"d/(.+)/view"))))

结果: enter image description here

© www.soinside.com 2019 - 2024. All rights reserved.