Generate random dates between two dates

Hi There,

I try to generate a random date between now and the upcoming 3 weeks with randbetween expression, which does not work: Parameter 1 of function RANDBETWEEN is of the wrong type

RANDBETWEEN(TODAY(), TODAY()+21)

I appreciate any help.

Kind regards,
Robert

Solved Solved
0 1 109
1 ACCEPTED SOLUTION

Please try

TODAY()+RANDBETWEEN(0,21)

RANDBETWEEN() works only with integers. So the above expression will add any random digit between 0 and 21 to todayโ€™s date and will give the same result you desire.

View solution in original post

1 REPLY 1

Please try

TODAY()+RANDBETWEEN(0,21)

RANDBETWEEN() works only with integers. So the above expression will add any random digit between 0 and 21 to todayโ€™s date and will give the same result you desire.

Top Labels in this Space