I\'m converting a date stored in a calendar object in a string for a query in MySQL. I need the string in format \"yyyy-MM-dd HH:mm:ss\", i.e.: \"2010-01-01 15:30:00\".
I\'m
That said, you should not convert to string in order to insert a date in the DB. You can either use the timestamp, or java.sql.Date together with PreparedStatement