
[英]Facing a difficulty in importhtml function, using order by and select col function but header is also being affected while importing in google sheets
[英]When importing HTML into Google Sheets, there are issues with the order by and select col functions as well as the header
我正在使用这个函数 =QUERY(INDEX(SUBSTITUTE(IMPORTHTML (I2 & "?refresh=" & I6,I3,I4), "*", )), "SELECT Col1, Col2, Col3, Col4 ORDER BY Col1 ASC" )
这是在表之间返回带有标题的数据。
此外,我们是否可以使用偏移量来完全避免标题,如果是的话,什么是正确的语法链接到导入页面
您不妨在 QUERY 中完成所有工作
=ARRAYFORMULA(
QUERY(
SUBSTITUTE(
IMPORTHTML("https://ipowala.in/ipo-subscription-status/?refresh="&I6,"table",1),
"*",""),
"select Col1, Col2, Col3, Col4
where not Col1 = 'IPO Name'
order by Col1",0))
这将放弃标题
如果您想在保留实际值的同时删除 * ,那就有点不同了。 我们可以利用转换为值的错误(双连字符)并在其中运行替换。
=ARRAYFORMULA(
QUERY(
IFERROR(
--IMPORTHTML("https://ipowala.in/ipo-subscription-status/?refresh="&I6,"table",1),
SUBSTITUTE(
IMPORTHTML("https://ipowala.in/ipo-subscription-status/?refresh="&I6,"table",1),
"*","")),
"select Col1, Col2, Col3, Col4
where not Col1 = 'IPO Name'
order by Col1",0))
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.