Help

This Product Ideas board is currently undergoing updates, but please continue to submit your ideas.

Formula Beautification & Debugging Tools

cancel
Showing results for 
Search instead for 
Did you mean: 
Zollie
10 - Mercury
10 - Mercury

Here are a couple ideas, but this is a topic I’m sure Airtable developers could have fun with:

  • Multi-line formula editor (then auto-minifying before submission)
  • Error code highlighting

But if that’s too ambitious, a simple code beautifier would be sufficient. This one unfortunately doesn’t play nice with Airtable formulas because of the braces { } in fields names.

15 Comments
itoldusoandso
10 - Mercury
10 - Mercury

Yes, mean the second option. Like in Excel there is Dependency tracker. Or in the genealogy language, if the current view I’m looking at, the view being the parent, I’m looking for its children, not the grandparents. The grandparents are in the formula, that’s correct :grinning_face_with_smiling_eyes:

itoldusoandso
10 - Mercury
10 - Mercury

Been 6 months and still nothing. Hope more votes will get some more attention from Airtable team.

I am suggesting a simple temporary fix.

I guess it’s a lot of effort to redesign the formula editor. I understand that. In the meantime, Airtable could just at a SIMPLE fix to the problem of not knowing where the error is. Just show the position of the error in the text. Instead of saying there is an ERROR in the formula, say ERROR AT CHARACTER 123 and the number 123 represents the position of the character within the formula. (When counted from the left, the error will be on 123rd character, including spaces).

This is a VERY SIMPLE fix and many would appreciate this by saving lots of time. Yes I can use 3rd party editors, but 3rd party editors syntax doesn’t match the Airtable formulas.

This fix requires just a few lines of code. Even I could do that even I am not a programmer.

Justin_Barrett
18 - Pluto
18 - Pluto

If you’re not a programmer, and especially if you have no idea what’s actually happening behind the scenes with Airtable’s formulas, you can’t say with that kind of certainty that you know how many lines of code it would take. I am a programmer, and I’m fairly confident that it would be quite a bit more than just a few lines.

From what little I know about how Airtable is developed, the formula language that we use is first converted to the actual programming language that Airtable is based upon. That means that the error is found after that conversion is complete and that other language is running tests to ensure that everything is valid. To do what you suggest, the developers would need to accurately convert back to the original formula and pinpoint the location of the error. Doing that with any degree of accuracy would be no small task.

Believe me, I would love to have that “simple” fix as much as you, but it’s not nearly as easy as you make it sound.

itoldusoandso
10 - Mercury
10 - Mercury

Okay. Well explained. Yes, I imagine it must be simple like it is in Excel. So I guess they need a syntax checker in the currend editor window and they don’t have one for that or they would need to do the way you explained. Now I feel more educated :winking_face:

kuovonne
18 - Pluto
18 - Pluto

I think that Airtable does some parsing before converting to the actual programming language. For example, if I have a typo in a field name, sometimes the formula editor specifically tells me that it does not recognize a specific field. The formula editor also knows what function I’m currently in and can show the parameters for that field.

Even so, I agree that overhauling the formula editor is probably a major job. It may be that Airtable has been working on it quietly behind the scenes and we will see a new editor in the coming year, … or maybe not.

In the meantime, I use a very specific style for writing my formulas with multi-lines. It doesn’t prevent mistakes in formulas (my spelling & punctuation leave a lot to be desired), but it makes identifying mistakes much easier. You can see examples of my formula writing style in almost any of my posts with formulas.