Create loop to create row for every second of day

Hi,

I'm trying to create a list of timestamps, one for each second between a start and end date.

So the result would be:
2025-01-06 9:00:00 AM
2025-01-06 9:00:01 AM
2025-01-06 9:00:02 AM
......
2025-01-06 4:59:59 PM
2025-01-06 5:00:00 PM

Struggling to follow the repeat loop guidance (which I imagine is the right thing to use), any advice?
The value of a second in numerical form is 0.0000115740740740741.

I've attached the morph.
Timestamp loop.morph (2.6 KB)

Hi Alistair
As is often within EasyMorph, there is more than one way to do this. Because dates and times are stored as numbers, the simplest would be using some math and the Sequence action. I've attached your morph with the steps to achieve it.
Timestamp loop.morph (5.6 KB)

I've included annotations with each action to try and explain what it does and why. Let me know if you have any questions :slight_smile:

Regards
Matt

1 Like

brilliant thanks! I thought the Sequence action might be the way but couldn't figure it out.

No worries! Technically you could combine a couple of the steps but I kept them separate so it was logical and therefore hopefully simple to understand.

1 Like