Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Custom date format in crosstab
cypherdj
Hi,
I have a crosstab based on a data cube with a group of data type Date. I select year and month for my groupings.
When I highlight the month sub-group, in the data editor, I can select the "Format DateTime" tab, then select Format as "Custom", and finally set the format code to "MMMM" to display the month value as text.
However, whether I preview or run, the month values are still displayed as numbers.
Is this a bug in Birt 2.2.2 or am I doing something incorrectly?
Thanks,
Cedric
Find more posts tagged with
Comments
Tianli
You can check the month binding in your crosstab, it is Integer type, so the dateformat will take no effect on that. Do following steps:
1, In your cube builder, you can define your month format by editing the month level.
2, Show the month level in your crosstab
3, You can check the binding of month is DateTime type and it is an attribute expression like: dimension["Date"]["month"]["DateTime"]
4, Specify the datefomat MMMM
It will show month as text January....and etc
I'm using BIRT 2.3.0, I don't remember whether 2.2.2 support this format definition in cube builder.
See attached report design(created by BIRT2.3.0)
cypherdj
Thank you so much, it worked indeed.
I simply selected the crosstab, went into the binding tab of the properties editor.
As you said, I could edit the binding there to DateTime data type and modified the expression to add ["DateTime"] and my formatting was then applied correctly.
Much appreciated,
Cedric