Take a look at
http://java.sun.com/j2se/1.4.2/docs/...ateFormat.html
To parse I would do something like:
String dateAndTime = userDateInput + " " + userTimeInput; // i.e. "31/12/2003 3:00PM"
SimpleDateFormat dateFormatter = new SimpleDateFormat( "dd/MM/yy kk:mm aa");
Date theDate = dateFormatter.parse( dateAndTime, new ParsePosition() );
...
// assume that the prepared statment is setup in some way
...
preparedStatement.setTimestamp( fieldNumber, new java.sql.Timestamp( theDate.getTime() ) );
// use timestamp if you want to remember the time component across multiple
// databases. setDate() truncates the time with some JDBC drivers.