Search code examples
google-sheetsgoogle-visualization

Google Sheet gviz csv export - two column labels not exporting


I'm trying to export this Sheet to a csv for use in a webmap using this link: https://docs.google.com/spreadsheets/d/1XQnp7RK-Ddq4wCjpHjmcnVEKood1U08kIfRGr8sDRoU/gviz/tq?tqx=out:csv&sheet=Sheet1

It works well, except that two of the column headers (lat, long) are not exporting and the column labels in the csv are blank. I tried to change the format of the cell from Automatic to Plain text, but that didn't fix it.


Solution

  • Findings

    It seems this is an issue with gviz api as there's an ongoing Google Issue tracker report about it. You may want to click the star icon on the top left of issue report page to indicate that your are also affected by this issue.

    UPDATE

    As an alternative solution, you may try this way as this will export the same csv file:

    https://docs.google.com/spreadsheets/d/1XQnp7RK-Ddq4wCjpHjmcnVEKood1U08kIfRGr8sDRoU/export?format=csv&gid=0

    Reference: Download link for Google Spreadsheets CSV export

    Test

    I did some quick tests on my end & after manually downloading the sheet file as a Comma Separated Values (CSV) file from the Google Sheet UI & after using the alternative solution, there's no issue with missing cells. But when using the gviz api link, the issue occurs:

    • enter image description here
    • enter image description here