Nisha Kala wrote:hi all,
can anyone tell how to convert string as-> Tue Nov 02 00:00:00 IST 2010 to date format of same type or to get date in ist format in java
I had told about SimpleDateFormat in my reply to other query. You can have a look at the API for SimpleDateFormat:
http://download.oracle.com/javase/6/docs/api/java/text/SimpleDateFormat.html
Edit: Also the String which you are going to parse in to Date should be in the required format other wise it will throw ParseException. For example- You have a String in- 10-11-2010 format and then try to parse it to- Tue Nov 02 00:00:00 IST 2010 will result in an exception.