cancel
Showing results for 
Search instead for 
Did you mean: 
Subscribe

How to convert Date from string format to java.util.Calendar format in WDJ for saving in MDM tables?

0 Likes
View Entire Topic
vijay_kumar49
Active Contributor
0 Likes

Hi,

Please check this code.


import java.text.DateFormat; 
import java.text.ParseException; 
import java.text.SimpleDateFormat; 
import java.util.Date; 
 
DateFormat df = new SimpleDateFormat("dd/MM/yyyy"); 
try { 
Date today = df.parse("19/08/2011"); 
System.out.println("Today = " + df.format(today)); 
} 
catch (ParseException e) 
{ 
e.printStackTrace(); 
} 

Please reffer [this|; and [conver String to Date|]thread.

Hope this helps!!

Thanks & Regards

Vijay

Edited by: VijaySAPEP on Aug 19, 2011 6:59 PM