how to convert timestamp to date in jasper report ireport designer 4.5.0

Yogendra Singh picture Yogendra Singh · Feb 28, 2012 · Viewed 13.4k times · Source

I need to convert or format my timestamp to date in the report I am generating using Jasper Reports iReport designer 4.5.0

I am get the stardate as 2012-04-01 12:00 AM and I want to convert or format it to dd/mm/YYYY.

How can I achieve this?

Answer

Lichuang picture Lichuang · Feb 28, 2012

In the iReport designer, you can set the pattern of fields or variables. Select the field and you shall see the properties panel on the right side. Then find the Pattern property and set it according to your need.