Airtable converts codes to characters before creating a CSV

Topic Labels: ImportingExporting
1608 3
Showing results for 
Search instead for 
Did you mean: 
5 - Automation Enthusiast
5 - Automation Enthusiast

I’m exporting CSV’s from Airtable and have introduced some fields which represent HTML code. This data is imported into wordpress blocks. I need to use commas in the text.

Here’s an example:

''&'<p style="text-align: center;">For a local, reliable &amp; friendly service call our <strong>'&Locality&'</strong> hotline today</p>'

In this example the software that parses the CSV delimits the data on the , after the word “local” as you might expect (even when enclosed by quotes).

No problem, I’ll use the unicode version of “,” which is &#44; and then the commas won’t exist in teh output but will still show correctly when output as HTML …

… but no, Airtable does an outstanding job and converts the unicode to a “,” and outputs it in the CSV as a “,” :frowning: It also does the same thing with #comma and other variants I’ve tried.

Does anybody know of a way of preventing Airtable from “helpfully” changing these codes? Any way of “escaping” them?

3 Replies 3

This is software outside of Airtable trying to parse the CSV generated by Airtable, right? What software are you using to parse the CSV?

Most people think that there is only one standard for encoding data in CSV format, but there isn’t. There also is variability in how different software parses CSV data. In my experience, Airtable takes a reasonable approach to encoding commas, quotes, and new line characters CSV.

Can you use different software to parse the CSV data?

5 - Automation Enthusiast
5 - Automation Enthusiast

Its a plugin with an import function and it doesn’t seem to ignore commas within quotes, it just sees a comma and splits the record. There is no alternative. The delimiter it is looking for can be changed from a comma, but Airtable cannot export using a different delimiter. Workable in so far as I could open the csv and re-export from excel using the alt delimiter , but its a lot of messing about as this isn’t a one off operation. I’m importing/exporting csv’s dozens of times a day.

If I have to, I’ll simply not include commas as punctuation in the text, it won’t matter too much.

My question was more that when I have the unicode text saved in an Airtable field and then export to csv, Airtable doesn’t export it as-is, rather it converts that text to a comma and then outputs that. Not helpful in many instances as there may be many other characters I may wish to represent with unicode validly , that Airtable is going to convert. I wondered if there was a way of escaping a sequence of characters so that Airtable would just export the text exactly as typed and not convert it back to ASCII.

You could contact the author if the Wordpress plugin with the issue and see if there is an update that fixes the issue.

That’s a lot of manual importing/exporting. There must be a way to automate this.

What about using scripting to create the CSV with a custom delimiter? Or using scripting to push the info to WordPress directly without messing with the plugin?

What about a third party service that exports to CSV with a custom delimiter?

Or is budget a limiting factor?