Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BIRT » Convert String Date to Date in BIRT3.7.1(Unable to convert string date into Date in BIRT3.7.1)
Convert String Date to Date in BIRT3.7.1 [message #800726] Fri, 17 February 2012 12:00 Go to next message
JP Redro is currently offline JP RedroFriend
Messages: 181
Registered: July 2009
Location: India
Senior Member

Hi All,

While developing a report in BIRT 3.7.1, i am getting error in Date column(String), which is from XML DB. I have tried with the following scenarios but no luck.

<VALUE-OF format="MMM-dd-yy" >dataSetRow["date"]</VALUE-OF>

df = new Packages.java.text.SimpleDateFormat("dd-MMM-yy");
myDate = df.parse(row["date"].value);
myDate;

Kindly suggest me.

Error Message as:
org.eclipse.birt.data.engine.core.DataException: Fail to compute value for computed column "date".
A BIRT exception occurred. See next exception for more information.
There are errors evaluating script "df = new Packages.java.text.SimpleDateFormat("dd-MMM-yy");

myDate = df.parse(row["date"]);

myDate;":

Thanks,
JP.


Thanks,
JP
Re: Convert String Date to Date in BIRT3.7.1 [message #801017 is a reply to message #800726] Fri, 17 February 2012 20:27 Go to previous message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

JP

Can you post an example value of dataSetRow["date"]?

Jason


On 2/17/2012 7:00 AM, JP Mising name wrote:
> Hi All,
>
> While developing a report in BIRT 3.7.1, i am getting error in Date
> column(String), which is from XML DB. I have tried with the following
> scenarios but no luck.
> <VALUE-OF format="MMM-dd-yy" >dataSetRow["date"]</VALUE-OF>
>
> df = new Packages.java.text.SimpleDateFormat("dd-MMM-yy");
> myDate = df.parse(row["date"].value);
> myDate;
>
> Kindly suggest me.
>
> Error Message as:
> org.eclipse.birt.data.engine.core.DataException: Fail to compute value
> for computed column "date".
> A BIRT exception occurred. See next exception for more information.
> There are errors evaluating script "df = new
> Packages.java.text.SimpleDateFormat("dd-MMM-yy");
>
> myDate = df.parse(row["date"]);
>
> myDate;":
>
> Thanks,
> JP.
Previous Topic:Add image from xml datasource to BIRT report
Next Topic:Erroneous Handlers - BIRT 3.7.1
Goto Forum:
  


Current Time: Thu Apr 25 20:11:56 GMT 2024

Powered by FUDForum. Page generated in 0.02914 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top