Hi Sithumini, I have used Joda-time library instead of SimpleDateFormat for formatting dates. You may able to use it. http://www.joda.org/joda-time/ http://blog.smartbear.com/programming/date-and-time-manipulation-in-java-using-jodatime/
Hasanthi Dissanayake Software Engineer | WSO2 E: [email protected] <[email protected]> M :0718407133| http://wso2.com <http://wso2.com/> On Mon, Feb 9, 2015 at 8:19 PM, Thusitha Thilina Dayaratne < [email protected]> wrote: > May be you can give a try on Natty <http://natty.joestelmach.com/> > > On Mon, Feb 9, 2015 at 1:54 PM, Sithumini Senevirathne < > [email protected]> wrote: > >> Hi All, >> >> I am working on a new feature, Solr based advance search in G-Reg. In my >> requirement date is passed in below format before index it in Solr. Below >> are the example date being passed and the standard Solr date format. >> >> String dateFormat = "Mon Feb 09 02:05:26 IST 2015"; >> The standard Solr format is "*yyyy-MM-dd'T'HH:mm:ss'Z*'" >> >> As the solution I tried SimpleDateFormat but the problem with this >> approach is, its not a generic solution to support various formats. So >> looking >> for a generic one available, which can cater to any date format. >> >> Is there a standard library to achieve this ? >> >> Thanks, >> Regards, >> Sithumini >> -- >> -- >> Sithumini Senevirathne >> Software Engineer >> WSO2 Inc. - lean . enterprise . middleware | wso2.com >> >> email: [email protected], mobile: +94 756977999 >> >> _______________________________________________ >> Dev mailing list >> [email protected] >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > Thusitha Dayaratne > Software Engineer | WSO2 Inc > > Email [email protected] > Mobile +94712756809 > Blog alokayasoya.blogspot.com > > > _______________________________________________ > Dev mailing list > [email protected] > http://wso2.org/cgi-bin/mailman/listinfo/dev > >
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
