Text column is being treated as number in formula

I have a column full of IDs.

0108
0109
0110

And it is a text column because they aren’t really numbers one would do some calculation with, and I need that 0 to remain there.

In another column, I applied the formula ID + ".png" but got 108.png instead of 0108.png. See gif

I worked around it by using CONCATENATE formula.

Thinking about it, maybe this is a feature (like coda trying to guess what I’m trying to achieve with the plus sign operator). But I’ll leave it here in case someone has the same problem.

Google Chrome - Untitled doc · Untitled page 2023-10-30 às 16.02.12

Compose column also respects ID column type and gives me 0108.png as result.

Can you please add your vote here:

1 Like

Thank you for pointing that out! I’ll delete this post

the problem is in using +

ID + “.png”

Coda Formulas are converted to Javascript under the hood, and Javascript does some really nasty type conversions with operators.

Solution: use concatenate() instead.

2 Likes