Choose Language Hide Translation Bar
Highlighted
qspringleaf
Level III

How to group time to YM(year/month, 1st half moth and 2nd half month)

How to group time to YM(year/month, 1st half moth and 2nd half month, for example, 20200401 means 1st half month and 20200402 means the second month.

thanks

 

 

Start TimeDATE GROUP
4/12/2020 1:5320200401
4/15/2020 1:5320200401
4/18/2020 1:5320200402
4/21/2020 1:5320200402
4/24/2020 1:5320200402
4/27/2020 1:5320200402
4/30/2020 1:5320200402
5/3/2020 1:5320200501
5/6/2020 1:5320200501
5/9/2020 1:5320200501
5/12/2020 1:5320200501
5/15/2020 1:5320200501
5/18/2020 1:5320200502
5/21/2020 1:5320200502
5/24/2020 1:5320200502
5/27/2020 1:5320200502
5/30/2020 1:5320200502
6/2/2020 1:5320200601
6/5/2020 1:5320200601
1 REPLY 1
Highlighted
Thierry_S
Level VI

Re: How to group time to YM(year/month, 1st half moth and 2nd half month)

Here is a formula that produces the Character String as you you requested

Char( Year( :Full Date ) ) || Char( Month( :Full Date ) ) ||
If( Day( :Full Date ) >= 15,
	"02",
	"01"
)

If you need a numeric value, I would simply precede the entire formula with Num ("formula")

 

Best,

TS

 

Thierry R. Sornasse
Article Labels