JBoss Community

Re: Error setting a Date type parameter

created by Carlos Celis Osorio in JBoss Tools - View the full discussion

Hi Snjezana.

 

I defined two other parameters in the report and I sent them from Report.java in the "yyyy/MM/dd" date format:

 

1. FechaInicioString (String)

2. FechaFinString (String)

 

I put the following at initialize() method of the report:

 

 

params["FechaInicio"] = Date.parse(params["FechaInicioString"]);
params["FechaFin"] = Date.parse(params["FechaFinString"]);

 

 

BIRT shows the next error in the web page:

 

 

The following items have errors:


Table (id = 14):
+ An exception occurred during processing. Please see the following message for details:
Failed to prepare the query execution for the data set: ElTiempoDataSet1
Cannot convert the parameter value 1,312,174,800,000 to type class java.sql.Date.
Can not convert the value of 1.3121748E12 to java.sql.Date type.

 

 

Thanks for your help.

Reply to this message by going to Community

Start a new discussion in JBoss Tools at Community