hgfree Posted June 16, 2009 Share Posted June 16, 2009 Hello,Using iReport 3.0.0 Running the report locally, not through Jasper Plugin. A datetime parameter has been set up (java.sql.Timestamp) and set to Use as a Prompt. The prompt appears OK. However, the sections for the time entry do not appear to work correctly. There are three sections for time input, which appear to be hours, minutes, and seconds. In the attached screenshot I entered 22:50:30 but the report output shows 22:30:00. The hour is OK, but the minute portion does not appear and the seconds appear where the minutes should appear in the report output. Any ideas on how to correct?Thank You,Chris Link to comment Share on other sites More sharing options...
hgfree Posted June 16, 2009 Author Share Posted June 16, 2009 One other attachment:The format pattern for the field to print:yyyy.MM.dd G 'at' HH:mm:ss z Z Link to comment Share on other sites More sharing options...
hgfree Posted June 17, 2009 Author Share Posted June 17, 2009 Another related note of interest:Using this basic query -select field_id, to_char(sysdate, 'dd-mon-yyyy hh24:mi:ss') as sysdate2,sysdate from source.tablewhere field_id = 123456I configure the sysdate field to display HH.mm.ss to see if it matches the to_char HH.mm.ss.This yields two different results depending if I run it locally through iReport or run it on JasperServer. The datasource connection is configured the same in both cases.The local result will display the correct time for our time zone (Eastern Time - USA) for both report fields sysdate2 and sysdate.The iReport JS Plugin result will display the correct time for sysdate2, but the sysdate field displays GMT.Also, the JS Plugin will not render in pdf, had to utilize the Jasper viewer...weird?From reviewing other threads, this appears to be related to a server setting somewhere. It is odd that the SQL captures the correct HH.mm.ss using the to_char, but the sysdate that is captured has a different HH.mm.ss. Link to comment Share on other sites More sharing options...
hgfree Posted June 17, 2009 Author Share Posted June 17, 2009 OK! Finally got it(time zone setting corrected) after reading every thread I could find regarding time zone...the datasource time. This is best noted in the JasperServer project. Screen shot attached, note the blue section of the datasource set up...LEAVE IT BLANK if your DB already reflects the correct time.Any notes on the Hour:Minute:Second parameter prompt would be much appreciated!Thank You,Chris Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now