Pulls a list of numbers between a starting and ending point that you provide
It’s kind of like saying...
Hey Coda, I’m going to provide you with two numbers: a starting and ending number. I want you to provide me with a list of the numbers between these two. Also, If I want you to count up by a different number than 1, can you do so?
Sequence() takes three parameters. Two are required and one is optional.
Start Sequence(Start, End, By) The number on the list to start from
End Sequence(Start, End, By) The number on the list to end on
By Sequence(Start, End, By) The number your list will count up by
Sequence() allows you create lists of sequential numbers or dates. As mentioned above, the formula defaults to counting up by 1; however, you have the option to count up by any number you wish by setting the By parameter to that number. Try it out below:
List of Generated Numbers:
The only difference between these list variations is the number hey count up by. Neat, right?!
Where and How To Use This
Though Sequence() can seem slightly useless at first glance, this formula is extremely versatile, and deserves a spot in your top 10 formulas! One important use is in back-end functionsor automations. Let’s look at a real-life use case to further illustrate how to use this formula.
Creating a list of dates
I often create a hidden page called “Date Controls” in my docs. It holds canvas-based formulas containing the relative dates of the current week, previous week, current month, and previous month. As an example, here is a canvas based formula named ThisWeek.
Now that I have a list of every date in a week that is named ThisWeek , I can create easy filters or buttons to quickly filter a table to contain only dates from ThisWeek. View my