Repeat
Repeat( value, [ number ] )
Repeat( value, [ number ] )
Repeat( value, [ number ] )
Repeat( value, [ number ] )
repeat( value, [ number ] )
Repeat( value, [ number ] )
Description
The Repeat
function returns a string consisting of the value
string repeated number
times.
Returns
A String with the value
string repeated number
times.
Examples
The following query executes an array of independent repeat operations and returns the results in an array. The result array position matches the execution array position. The individual operations are:
-
The string
Yes
is concatenated with itself. The result stringYesYes
is placed in the top position of the result array. -
The string
Yes!
, containing a trailing space, is repeated 3 times. The result stringYes! Yes! Yes!
is placed in the second position of the result array. -
The string
=
is repeated 10 times. The result string==========
is placed in the third position of the result array.
Arr(StringV(YesYes), StringV(Yes! Yes! Yes! ), StringV(==========))
[YesYes Yes! Yes! Yes! ==========]
["YesYes", "Yes! Yes! Yes! ", "=========="]
[ 'YesYes', 'Yes! Yes! Yes! ', '==========' ]
['YesYes', 'Yes! Yes! Yes! ', '==========']
[ 'YesYes', 'Yes! Yes! Yes! ', '==========' ]
Is this article helpful?
Tell Fauna how the article can be improved:
Visit Fauna's forums
or email docs@fauna.com
Thank you for your feedback!