
Anonymous
Not applicable
2016-05-19
08:10 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How to add months to YYYYMM format
Hello everyone,
I have the following date format: YYYYMM. I would like to add a month to this format,
but it doesnt seem to work correctly.
for example, if I have a date 201201, the new value must be 201202.
If I have a date 201212, the new value must be 201301.
Help will be appreciated.
Thanks,
Stefan
5,386 Views
6 Replies

Anonymous
Not applicable
2016-05-19
08:12 AM
Author
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
use this expression
addmonths(date#(yourdates,'YYYYMM',1)

MVP
2016-05-19
12:00 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
and to format is again as YYYYMM, you can use Date() function
Date(AddMonths(Date#(yourdates,'YYYYMM',1), 'YYYYMM')
4,050 Views

Not applicable
2016-05-19
12:30 PM
Author
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
=Date(MonthEnd(Date#(YourValue, 'YYYYMM'))+1, 'YYYYMM')
4,050 Views

Creator III
2018-07-17
04:53 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Not getting the required format.
Thanks..
4,050 Views


Specialist III
2018-07-17
05:36 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
maybe that
let m=201212;
let m1=date(AddMonths(date#(m*100+1,'YYYYMMDD'),1),'YYYYMM');
4,050 Views

MVP
2018-07-17
07:09 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for providing this information
4,050 Views
