Java tutorial
//package com.java2s; import java.text.SimpleDateFormat; public class Main { private static String toNYR(long data) { SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-M-d"); try { return dateFormat.format(data); } catch (Exception e) { return ""; } } }