java - Change date output format -


I am using H2DB in my Java application and I need to get its date. Everything is fine, but I got a 1-digit number or a month's number, it gives me a format of 2014-4-8. Is it possible to achieve something like this (2014-04-08), without zero and without formatting through the application?

If you use struts2 at the front end. Belo tags can be useful to you

  & lt; S: date name = "somedate" format = "EEE, MMM dd, Yyyy" />    

Comments

Popular posts from this blog

asp.net - Procedure or function "Procedure name" expects a parameter "Param name" which was not supplied occurs rarely -

c# - The item with identity 'Id' already exists in the metadata collection. Parameter name: item -

c++ - Redefined variable in the other module -