Error in report calculation / Hierarchical data in Reports

Hey there.

Given a simple database with a name field and an (integer) number field, why does the following formula throw an error?

image
image

What am I missing?

On a related note: What other options do I have to display recursively hierarchical data in a report table? (Items with self-relation)

Best,
Lars

If [Number] is a number field, I’m not sure that you can use LEFT() on it

That is odd… I use a similar formula that works :+1:

 Left("—  —  —  —  —  —  ", 3 * (Depth - 1)) + Name

(Depth is a numeric Formula field)

I realise now that the formatting on my phone was misrepresenting your formula, and I thought it was LEFT('[Number]') :man_facepalming:

Now I see what you’re doing, and my guess is that LEFT requires the second argument to be an integer literal, and won’t work with a variable.
I’ll double-check with the devs.

Note: report formulas can behave differently to db formula fields