Synthoid/ExportSheetData

hide sheet_tab title in generated .json

Closed this issue · 17 comments

Hi @Synthoid,
Happy new year, and thank you again for this life saving repo !
Do you know if there is a way to remove the spreadhseet title ?
ESD automatically generate below code on top of the file :

{
  "spreadhsheet_tab_title":
...
}

So far I remove it manually,
Would be a useful to spread the tool to colleagues allergic to text editors.

Haha, that's a surprisingly common allergy. Are wanting something like sheet unwrapping?

Exactly, but it is not single row sheets.

I can add that. Probably just make the Unwrap Prefix work with multiple rows but keep the Unwrap Single Row Sheets option the same functionally.

I forgot to mention this, but if you are only exporting a single sheet, you can achieve this by setting Export Sheet(s) to Current sheet only.

Yes I was using Current sheet onlyfailed to get the Unwrap single row effect though,
Did you change something past few days ?

My schedule has prevented me from working in ESD for the past few weeks, so I haven’t touched the code since the last update. Is it working for you now?

Sorry no difference,
I am supposed to write something in the cell below wrap ?
US_

You can get rid of the US_ prefix when exporting just the current sheet. I wonder if having both options set will actually interfere with the unwrapping process? I'll take a look and see what I can find!

I'm sorry I haven't a clue,
By the way, we are using ESD as a model to send spreadsheet data to mongodb,
Would you find it interesting to adapt this app script into ESD for other mongo users ?
If so where would you prefer pm ?

I've been eyeing MongoDB support for a while now actually. Feel free to PM me if you want to discuss in detail.

This has been added as of v59. That update should be going live later today.

Thank you for staying on top of this.
I gave it a try, not sure I am doing it correctly (screenshot below)
Capture d’écran 2020-01-29 à 14 36 52

Unwrap sheet prefix is a prefix to the name of the sheet tab. By default, this prefix is set to US_ so if you wanted to unwrap a sheet named:

Sheet1

You would change its name to:

US_Sheet1

This will cause the sheet to be unwrapped and its elements placed in the root JSON object.

Sorry to be so finicky but it is not working on my side.

Capture d’écran 2020-01-30 à 09 57 39

Capture d’écran 2020-01-30 à 09 58 10

You want the Unwrap sheet prefix to be set to US_ and the sheet name to be US_Sheet1 that should export your data properly.

Hey @Synthoid !
Hope you're ok,
Sorry to rekindle this, but would it be possible when extracting to keep the arrays brackets on top and bottom ?
[ ]

So that user have "nothing" to do but click.
Thanks again for support