Upcoming database upgrades. Airtable functionality will be reduced for ~15 minutes at 06:00 UTC on Feb. 4 / 10:00 pm PT on Feb. 3. Learn more here

Script to change field type

Topic Labels: Scripting extentions
917 6
Showing results for 
Search instead for 
Did you mean: 

Hi All!

Can anyone provide some scripting advice - I want to create a script that changes a field type from Multiple Select to a Text field when it runs, and another script to do the reverse.

Thanks in advance for any feedback!

6 Replies 6

Scripts cannot change the field type of an existing field. Scripting app can create new fields, but it cannot delete fields.

Why do you want to change the field type?

Many thanks Kuovonne, I did not realize this scripting limitation… I’m creating an airtable form that would include a multiselect dropdown field, however I want it to only show drop-down options that are currently present in that table. Older items which were previously selected as drop-down option (but are no longer selected in the table) would ideally be excluded from showing as drop-down options in the form. Currently, drop-down options will show all current and previously added drop-down options unless you go in and manually delete older ones no longer in use.

Interestingly, one way to clear the “old” unused options would be to convert a field from a drop-down to a text field and then back to a drop-down. It will result in the drop-down options only being the ones currently in the table.

I’m not sure if there is another way to automate the deletion of older drop-down items…

There is no way to programmatically delete choices from a multi-select field.
You might want to consider using a linked record field instead.

Good to know, thanks for your help! :thumbs_up:

Not certain if you landed somewhere with this yet.
but here is the solution using linked fields.

Have 2 tables

Table 1

  • all of your selections listed out in “Name” field
  • Date field (manual expiry date OR created/modified time)
  • [Any other applicable data you want to include]

Then create a view that filters out the data based on whatever date field you chose.
(i.e. I want all selections where the record was made within 30 days.)



Table 2

  • Name field is whatever you like, [but perhaps a formula field concatenating certain data together.]
  • Link field to Table 1 (when creating this make sure you select “Limit to view” toggle and select the view that filtered out the data in Table 1.

Form will replicate the linked field that has limitation to that view

Thanks so much for the helpful feedback @Josh_Stockbridge!