Your formula works fine for me here – which makes me think the problem is probably related to GMT processing. (Would you be in the UK?) If I configure {Show Date}
to use a time field and set the timestamp so that {Show Date}
and GMT date are off, I can reproduce your problem.
Unfortunately, as far as I know the only way to correct this is to use SET_TIMEZONE()
. (I thought Airtable used to support the GMT toggle on datetime fields without time stamps — but if so, it doesn’t any longer. I’ve messaged Support to ask.)
To use SET_TIMEZONE()
, you’d need to do this:
VALUE(
DATETIME_FORMAT(
SET_TIMEZONE(
{Show Date},
[TZ]
),
'w'
)
)-VALUE(
DATETIME_FORMAT(
DATETIME_PARSE(
'01'&DATETIME_FORMAT(
SET_TIMEZONE(
{Show Date},
[TZ]
),
'MM')&DATETIME_FORMAT(
SET_TIMEZONE(
{Show Date},
[TZ]
),
'YYYY'
),
'DDMMYYYY'
),
'w'
)
)+1
(I think that’s right, but I haven’t tested.)
You’ll need to replace ‘[TZ]
’ with your local timezone, chosen from this list.
If that doesn’t fix it, let me know and I’ll flail about wildly again…