BirtDateTime calculation wrong? [message #629127] |
Mon, 27 September 2010 10:08 |
Eclipse User |
|
|
|
Originally posted by: abel.macadam.eden.invalid
Hi,
The report I build needs column heading containing the months, starting
with the previous month, the next column two months ago, etc. The
required result would be (as September is the current month)
aug jul jun etc.
(when the output is formatted as Date Time Custom MMM)
I can get this using the following formula:
BirtDateTime.addMonth(BirtDateTime.now(), -1) for the previous month
BirtDateTime.addMonth(BirtDateTime.now(), -2) for two months ago
etc.
However, when I get to:
BirtDateTime.addMonth(BirtDateTime.now(), -10)
I get unexpected results. Instead of
jan
I get
27 nov 2009 12:06
Instead of dec I get 27 okt 2009 12:06
What am I doing wrong?
Abel.
|
|
|
|
Powered by
FUDForum. Page generated in 0.03085 seconds