Skip to main content
Solved

Turning a multi-line cell into multi row in Airtable

  • May 6, 2025
  • 4 replies
  • 168 views

Forum|alt.badge.img+2

Hi there!

I want to transform a ChatGPT output (30 words/names) into a multi-line column (30 lines) in Airtable. I'm using Make as my automation engine and its Iterator module. I'm having trouble finding the right array formula

here is the one I have: split(trim({{5.choices[].message.content}}); newline)

It would be awesome if someone could help me!!

 

Best answer by TheTimeSavingCo

Hm, that looks fine and the following set up creates one record per variable value (i.e. creates record “a”, “b” and “c”) as expected:

Could you provide an example of the ChatGPT output that you’re splitting?

4 replies

Mike_AutomaticN
Forum|alt.badge.img+28

Hey ​@pvieljeux I’ll try to get back to this one tomorrow from my pc (currently on my phone). 
 

However if you are not too deep into Make already, I might suggest you give n8n a shot (check diferentes here). You could very esily achieve this with a code node, and you could have chatgpt provide such code for you. 
 

Also, I would suggest you ask Chatgpt to return a JSON as that will be easier to handle. 
 

Mike, Consultant @ Automatic Nation 


TheTimeSavingCo
Forum|alt.badge.img+31

Hm, that looks fine and the following set up creates one record per variable value (i.e. creates record “a”, “b” and “c”) as expected:

Could you provide an example of the ChatGPT output that you’re splitting?


Forum|alt.badge.img+2
  • Author
  • New Participant
  • May 7, 2025

Thanks guys!

My output is a list of hooks for Linkedin posts. There are 30 of them and I want those that are validated by the user, to automatically create a post. I want to have one column of hooks, one of check boxes, and then another one with the associated post that is automatically generated. 

I used a parsed JSON right after an OpenAI Chagpt Module, then an iterator, then an Airtable Create a record and then an Airtable Update a record. The array I used in the iterator is trim(parseJSON({{5.choices[].message.content}}).*)

The JSON string is {{5.choices[].message.content}}. The thing is that I get 30 lines, but all of them with all the 30 hooks in every cell. I want one hook per cell. :) - I’m almost there!! 

Any idea? 


Forum|alt.badge.img+2
  • Author
  • New Participant
  • May 7, 2025

Thanx Adam,

it was very helpful,

I figured out how to make it work thanks to your comment