First let me say that my question is slightly different from some similar ones already on SO, or at least different enough that other answers are not helping me. E.g.,: JasperReport parameters works in iReport but fails on JasperServer There are others dealing with timestamp problems that also haven't helped me.
I'm a newbie to JasperReports. The question linked above was solved by adding input controls to the report definition in iReport, which would then be exported to JasperServer. That much works fine for me.
My problem is with a report having a query with a timestamp parameter and an input control. I have assigned a default value of java.sql.Timestamp(0) to the parameter. Everything works fine when I open iReport and generate the report using the "Run on JasperServer" option, the input control shows up with the proper default value. However if I run the same report from a browser connection the default values don't work. The controls show up with defaults of some date, I think, in 1969. The input controls still work, can enter a value and the report runs properly, but the browser input controls don't get the default value.
I suspect the problem may arise because the input controls are defined as having datatype of datetime, not timestamp. However if that's the case I can't figure out why the defaults work fine in the input controls in iReport but not when the report is run from the browser. I've read various posts where someone has said that java.sql.Timestamp was not supported by JasperServer before ver 3.5. I'm using most recent version but I still can't figure out how to add a timestamp type to the server repository (or whether it's necessary, since things seem to work fine with datetime type other than my problem with default values).