Java Timestamp Now getCurrentSQLTimestamp()

Here you can find the source of getCurrentSQLTimestamp()

Description

get current SQL Timestamp returns a date in following format: 2003-04-01 08:21:57.556

License

Open Source License

Declaration

public static java.sql.Timestamp getCurrentSQLTimestamp() 

Method Source Code

//package com.java2s;
/* $This file is distributed under the terms of the license in /doc/license.txt$ */

public class Main {
    /**/*w w w .  jav a2 s .  c o m*/
     * get current SQL Timestamp
     *
     * returns a date in following format: 2003-04-01 08:21:57.556
     */
    public static java.sql.Timestamp getCurrentSQLTimestamp() {
        java.sql.Timestamp sqlTime = new java.sql.Timestamp(System.currentTimeMillis());
        return sqlTime;
    }
}

Related

  1. getCurrentAgeForDate(Timestamp birthDate, Timestamp endDate)
  2. getCurrentDateAsTimestamp()
  3. getCurrentDateTimestamp()
  4. getCurrentDBTimestamp()
  5. getCurrentSQLTimestamp()
  6. getCurrentTimeStamp()
  7. getCurrentTimeStamp()
  8. getCurrentTimeStamp()
  9. getCurrentTimestamp()