How to create calculated field in domain designer for YEAR function?

0

I need to create a calculated field using a field in jasper domain designer. I have a field called Report Date. Form the Report Date field i need to create a calculate field which hold the Year of Report Date field.

I have tried the YEAR(Report Date)  function. But when i tried to use in reports i am gettign error. please help me on this.

raja.shekar's picture
Joined: Apr 21 2014 - 12:28am
Last seen: 4 years 8 months ago

What is the data type of 'Report Date'?

Exactly what error do you get?

 

djohnson53 - 4 years 8 months ago

I created the report using the  iReport and created the variable for report year and given the variable expression as below and the issue is fixed.

new Integer($F{"Field name" }.getYear()+1900).

 

Thanks for the reply.

raja.shekar - 4 years 8 months ago

0 Answers:

No answers yet
Feedback
randomness