I want to use the importxml in the spreadsheet to get the YouTube channel name from the url, but I get the following error.
How can I solve this?
use:
=REGEXEXTRACT(QUERY(FLATTEN(IMPORTDATA(A4)),
"where Col1 contains '\x22channelName\x22:\x22'", 0), ":\\x22(.+)\\x22$")
Related
Asked this same question before and got the answer and it works fine too. This is how I want the answer in the formula I give.
Please read : Match lookup value with importHTML and combine tables in Soogle Sheet
#rockinfreakshow Thank You so much for this answer. Sir please answer me according to my formula.
---------------------------------------------------------------------------------------------------------------------------------
I want the answer in the same way, but I match the lookup value from another url link with them in the same way as the answer comes from the formula I show and I want the answer.
I have this formula. And I get the answer well. Which you will get with the result in the link of google sheet below.
1st URL : https://www.screener.in/screens/881782/rk-all-stocks/?limit=25&page=1
=arrayformula(
lambda(
baseUrl, pageStart, pageEnd,
query(
reduce(
importhtml(baseUrl & pageStart, "table"),
sequence(pageEnd - pageStart, 1, pageStart + 1),
lambda(
result, pageNumber,
{
result;
iferror(
importhtml(baseUrl & pageNumber, "table"),
iferror(sequence(1, 11) / 0)
)
}
)
),
"where Col1 is not null", 1
)
)(
"https://www.screener.in/screens/881782/rk-all-stocks/?limit=25&page=", 1, 57
)
)
Result Screenshot
2. And there is another table in which I want to match the lookup value of the first table and all the values of that table. Which I have tried. Within this google sheet and you can also try this google sheet.
2nd URL with match 1st URL Record : https://www.screener.in/screens/881791/rk-holding/?page=1
=BYROW(B2:B,LAMBDA(bx,IF(bx="",,IFNA(QUERY(IMPORTHTML("https://www.screener.in/screens/881791/rk-holding/?page=1", "table",1),"Select Col12, Col13 Where Col2='"&bx&"'",0)))))
If I use this formula I get only 25 data.
Result Screenshot
If I use this formula I get only 1 page of data. As this url link has more than 165 pages.
i expected result
I only get as much data as in the first formula. Next to them i.e next to ROCE you need column number 12 and 13 from another URL link. Lookup values match and look for the data next to them. Lookup value column number will be 2. Which I have tried in this google sheet and you can also try.
try this in google sheet : OPEN GOOGLE SHEET
Thanks
Updated the solution in your sheet here
I have this as my first query
=Query({'Cut request '!A2:S;'Out sent '!A2:S},"Select Col1,Col2,Col4,Col3,Col10,Col13,Col17,Col19 Where Col4 is not null",0)
I want to combine both with this
QUERY(leadlist!A2:Q,"Select I,M Where A is not null",0)
I tried doing this but got an "Formula parse error"
=Query(ARRAYFORMULA({'Connection request '!A2:S;'Message sent '!A2:S},"Select Col1,Col2,Col4,Col3,Col10,Col13,Col17,Col19 Where Col4 is not null",0};QUERY(leadgen!A2:Q,"Select I,M Where A is not null",0)}))
I can not figure out how to combine both to make it works
Please any help. Thanks in advance, appreciated.
With exactly the same number of columns, it will be ok (as Sergey said). For instance :
={Query({'Cut request '!A2:S;'Out sent '!A2:S},"Select Col1,Col2,Col4,Col3,Col10,Col13,Col17,Col19 Where Col4 is not null",0);QUERY(leadlist!A2:Q,"Select A,B,C,D,E,F,G,H Where A is not null",0)}
I am trying to extract a couple of elements using the =importXML function in Google sheets from this source: https://www.ibm.com/homepage_sitemap.xml
=IMPORTXML("https://www.ibm.com/homepage_sitemap.xml","//url[*]/loc")
It is throwing me a N/A error. Below picture is what I would like to extract. Also, href= against each hreflang value but I am stuck at the first extraction.
You can try using this formula:
=IMPORTXML("https://www.ibm.com/homepage_sitemap.xml","//*[local-name() ='url']/*[local-name() ='loc']")
try:
=IMPORTDATA("https://www.ibm.com/homepage_sitemap.xml")
and to get url:
=ARRAYFORMULA(QUERY(REGEXEXTRACT(
IMPORTDATA("https://www.ibm.com/homepage_sitemap.xml"),
"(http.+/)"""), "where Col1 <> '#N/A'"))
I want to extract the sale info from this link with importxml
link
My formula:
substitute(substitute(to_text(index(IMPORTXML(strong textLINK;"//div['before-sticky-nav']//div['trust-signals col-group content no-banner']//div['show-lg show-xl show-tv shop-info col-lg-7 pl-lg-3']//p['trust-signal-row text-gray-lighter']/span[3]");1));" Sales";"");" Sale";"")
The formula has been working for 1 month, yesterday it didn't work. I've tried many variations of the xpath still no luck.
Any ideas?
=VALUE(REGEXREPLACE(REGEXEXTRACT(QUERY({ARRAY_CONSTRAIN(IMPORTDATA(
"https://www.etsy.com/shop/1000Lightyear"), 4000, 1)},
"WHERE Col1 CONTAINS 'mr-xs-2 pr-xs-2 br-xs-1"">'"),
"\>([0-9 A-Za-z]+)\<"),
" Sales| Sale", ""))
I don't know why but when put two sources in QUERY command, I get #ARG! error. Can somebody tell me why?
https://docs.google.com/spreadsheets/d/1jzhsqVD5oeokraoKcu4C2AnnlzBBVvbD_lONBKrgk-I/edit#gid=387365472
You cant ref to A, B [..] when merged input data use Col1, Col2 [..]