kcm
kcm

Reputation: 200

Return multiple index Google sheet

This is my query to the espn site for football data when I run the below code this returns only the first column not the full datatable

=IMPORTHTML("https://www.espn.in/soccer/table/_/league/eng.1","table",1)

When I run this =IMPORTHTML("https://www.espn.in/soccer/table/_/league/eng.1","table",2) it returns the datatable but it omits the first column which contains rowname.

Any suggestion how to include both of them?

Upvotes: 0

Views: 317

Answers (1)

marikamitsos
marikamitsos

Reputation: 10573

You can use

=ArrayFormula(
     {REGEXREPLACE(IMPORTHTML("https://www.espn.in/soccer/table/_/league/eng.1","table",1),"^\d{1,2}\D{3}",""),
                   IMPORTHTML("https://www.espn.in/soccer/table/_/league/eng.1","table",2)})

enter image description here

Functions used:

Upvotes: 2

Related Questions