Home > Software design >  iMPORTXML is returning #NA (imported content is empty) in some cells and #REF in some cells in Googl
iMPORTXML is returning #NA (imported content is empty) in some cells and #REF in some cells in Googl

Time:07-19

Ok. so i'm tring to import a couple of data from different urls on the same google sheet using IMPORTXML function. it works on some cells and it returns #NA (imported content is empty) on some and #REF(Array result was not expanded because it would overwrite data in H16.) on some cells. I need help right now. This is the formula in one of the cells returning #NA imported content is empty:

=IMPORTXML(N9;"//ul[@class='important-attributes-list']/li[2]/div/div")

And this is the url i am extracting the data from:

enter image description here

#N/A

... in E12 and F12 is due to the lack of ul class=breadcrumbs__list theme--light in the source of the web page, clarify whar you are looking for

in F12 you can use

=index(IMPORTXML(N12;"//a[@class='product-link-attribute__link']");2;1)

You should probably reduce the number of calls inside the urls

edit:

reduce drastically the numbers of calls, for instance, in I9, you could fetch all data at once using this global xpath

"//ul[@class='important-attributes-list']"

it will be easy then to detailed the informations inside the multi-cells result

This will solve quite 100% of your errors.

enter image description here

  • Related