Show next 7 dates after a specific starting date (YC?)


@Darren_Murphy noted this a little while ago, but it seems as though the Math column and date calculations aren’t working great — you can’t force the date format when performing a calculation.

I have a date column (Single Value) and a number column (0-7). I use this in another app and it works well — I have a Math column that adds the number to the date, which then returns the first date followed by the next 6 dates (so a full week of dates). This trick was given to me by @Jeff_Hager

Now though, that approach isn’t working because the Math column is forcing the result to be a number and not a date. I’ve tried all sorts of ways to force the date format but it’s not working. It does still work in my original app though!

I’m wondering if there’s a way to use the Experimental Code column achieve the same result. The goal is to have a column of 7 dates, where the first date is known/provided by a single value and the next 6 dates are the ones after this given date.

Thanks for any help!

1 Like

Hola @kyleheney

@Manu.n helped me out with a column that gives me an array of dates between two dates. He may be able to help with this case.

1 Like

Hello friends
yes it is possible in YC (even if I am surprised that the Math function does not return a date with the calculation !!)
the returns in return, you need an array just one string with separator ‘,’ ???

this is YC

YC Link

YC Source

the format will depend on the language of your browser (with me it’s French so dd / mm / yyyy) but if you are in us normally the format will be mm / dd / yyyy !!

in this YC, only the date is returned, but it is possible to return date & time !!!


Hi @Manu.n !

Thanks for the help. My goal is to get a single column with one date per row — like this:

Single Value. Dates
September 1, 2021. September 1, 2021
September 2,2021
September 3, 2021
And so on til September 8

Edit: I’ll clean this up when I get to my computer. Didn’t format well through mobile.

I just tried as you described, and it seems to work fine?


I add 2 parameters
a short, medium, long format
a separator between dates

WTH! Let me rearrange my columns and see if it works… the only difference I can see is that your SV is before your Number column.

The result I’m looking for is exactly what @Darren_Murphy showed above.

1 Like

haha, if column ordering makes a difference then we have a serious problem, Houston :rofl:

Okay it’s working now… and I found my error. I converted my original date to a text using a template column and my Single Value was pulling from that template column instead of the original date column. I changed it to look at the original date and it’s working.

Appreciate the efforts, but I think this one was just my brain cramp issue!

1 Like

That would do it (and I can relate) :laughing:

1 Like

When you’re writing to the Increment column, are you writing each number value shown in one set of actions? I’ve tried this in the actions and the cells don’t get written sequentially, the 2 and 4 will be transposed, for example. I even tried to add a “go back” action between to try to ensure one cell is finished writing before the next write step starts to process.

The actions may complete too fast and jump on top of each other, I had this behaviour when trying to mass upload data to Glide Tables using add row actions, but in my case the order was not so important.

1 Like

You only update the first row. The increment is pre-populated on all of the other rows. I call these work tables. You pre-populate all of the rows you need, then something like a single value column pulls in the dynamic value and the whole table calculates based on that dynamic single value.

That’s what I did here. One small table dynamically adapts to show an endless number of months.


What Jeff said. :arrow_up:
I find myself using “working” tables more and more these days. I find them particularly useful for dashboard type screens.
I blame Jeff for this.

1 Like

Very neat, I’m checking out the backend now. Thanks!

1 Like

I suppose I do the same, to try to avoid as many custom actions as possible. Custom actions are too hidden for my liking.

The roster that Jeff helped me build in that thread is still working, several months later.
Monthly shift rosters for roughly 500 employees are managed outside the app, and syncronised with the app several times a day. It’s been a brilliant solution and I rarely have to touch it. It just works.

1 Like