Importing data from links to google sheets - google-sheets

I have a list of links from which I have to manually detect if the product is in stock or not. Is there any import function in google that I can use to identify whether or not the specific product is in stock without opening the link. Can Importxml or importhtml be used?
https://www.katespade.com/products/the-little-better-sam-daisy-dots-small-shoulder-bag/767883202005.html?cgid=ks-new-arrivals-view-all

try:
=IMPORTXML(A1, "//div[#class='jss250']")

Related

Google Sheet: Get Data from NSE website to Google spreadsheet

I want to import data i.e. Issued Cap. and Free Float Market Cap. from this website:
Edit: 11-Jun-2022
https://www.nseindia.com/api/quote-equity?symbol=TRITURBINE
in Company information sector to a Google sheet.
I have tried Importhtml, Importdata and Importxml...but they all give an error or return #N/A.
Any suggestions would help greatly.
import formulae of google sheets do not support the scrapping of JS elements. you can always test this by disabling JS on a given site and usually, what's left can be imported into a spreadsheet. in your case fields are blank:

IOS with sheetDB and google sheets issue

I make a static website, and use form on html, which links to google sheets through sheetDB.
Then it’s can use from and save the value on google sheets only on non-ios system.
And I can’t find out how to solve it. please help

How to get websites logos with google sheets IMPORTXML with //img/#src?

I have a google sheet list with different companies and their website addresses. I am building a small app in glide and would like to include the companies logo. In my google sheet I want to have a URL to the logo image. Is there any way how I can filter out the other images, that I am getting with //img/#src? Please help me find the function for =importxml(E3,"//img/#src") -->get only logo.
Thank you for your help
my table
For the first one, you can use
=IMPORTXML("https://www.xolo.io/zz-en","//link[#type='image/png']/#href")
No possibility for https://1office.co/ (the website uses javascript)
Third one
=importxml("https://www.firma.de/","//meta[#property='og:image']/#content")
you have to retrieve the specific xpath for each url

Importing a website table into Google Spreadsheet

I am trying to import this table into a Google Spreadsheet:
The table is available here:
https://competitions.lta.org.uk/sport/drawsheet.aspx?id=8D598CDE-8579-4541-B7AD-48558BF6FEA3&draw=4
Before Google changed their Spreadsheet addresses, I had the import working with ImportHTML(URL, "table", 2) - but this no longer works, even though there appears to be only two 'table' labels in the page HTML.
Looking for a way to abstract the table, I went to 'importXML' but tried several versions like 'importxml("https://competitions.lta.org.uk/sport/drawsheet.aspx?id=8D598CDE-8579-4541-B7AD-48558BF6FEA3&draw=4", "//div[contains(#id,'poule')]")'
and the same first part of the statement with "//table[contains(#class,'ruler')]")
but the formula fails with 'no content'
Would really appreciate some help to find a way to import this table!
Thanks in anticipation,
The reason you can't get the table data is because of the cookies page
Every time Google Sheets is trying to access that link, you need to accept cookies, and by default, Google Sheets won't do it.
You need to bypass or accept the cookies from the website to access data, you will need to implement more advanced things in Python or Google Apps Script

How to scrape an income statement from Yahoo Finance into google sheets

I'm trying to scrape an income statement for Apple (AAPL) into google sheets
https://finance.yahoo.com/quote/AAPL/financials?p=AAPL
First off I'd like to say I'm new to using anything technical or function related for computers so sorry if its a dumb question but I'm aware sheets has built in import functions for web data and I tried using the IMPORTXML function and I couldn't find the right xpath for the whole income statement
So my questions are
Which Import function would be best for scraping the income statement into sheets
Whichever function is the best how can I do it.
Would I repeat the steps that you show me if I wanted to scrape the balance sheet and cash flow as well
Thank you for your time
It seems that you are trying to fetch dynamically generated data in the link you've provided. Import functions cannot be used or cannot function properly in dynamically generated data as well as in websites which data are being controlled by JavaScript.
I suggest finding another link or website that will provide you with the same data and can be fetched through IMPORT functions by taking into consideration the mentioned limitations above.

Resources