Joined: Thu Mar 26, 2009 4:41 am Posts: 2				
			 | 
			
				
				
					| 
					
						 I have defined 1 column in table as Created_On with type as timestamp.
 Now, when in servlet i am writing sad.setACreatedOn(timeStamp);
 sad is the object.
 
 Even on writing  it in try-catch block:-
                   
                 timestampDate = request.getParameter("timestamp");
 
 		try{
 			DateFormat formatter = new SimpleDateFormat("dd/MM/yyyy");
 			
 			Date dob = (Date)formatter.parse(date);
 			Date timeStamp = (Date)formatter.parse(timestampDate);
 			sad.setDob(dob);
 			sad.setACreatedOn(timeStamp);
 			sad.setALastUpdatedOn(timeStamp);
 		} catch (ParseException pe){
 			log.error(pe.getMessage());
 			log.error(pe.getLocalizedMessage());
 		}
 		catch(Exception e)
 		{
 			log.error(e.getMessage());
 		}
 
 It is giving error.
 Is it the Correct way?
 Give suggestions 
					
  
						
					 | 
				 
				 
			 |