This methods returns "1996-12-13 14:15:25." instead of
"1996-12-13 14:15:25.0" or "1996-12-13 14:15:25" or "1996-12-13 14:15:25.000000000"
(it is not clear from specification which result is correct)
==== Here is the test demonstrating the bug ====
import java.sql.Timestamp;
class java_sql_Timestamp6 {
public static void main (String args[]) {
Timestamp ts=Timestamp.valueOf("1996-12-13 14:15:25.0");
System.out.println("ts = " + ts);
}
}
=== Here is the test output ===
ts = 1996-12-13 14:15:25.
"1996-12-13 14:15:25.0" or "1996-12-13 14:15:25" or "1996-12-13 14:15:25.000000000"
(it is not clear from specification which result is correct)
==== Here is the test demonstrating the bug ====
import java.sql.Timestamp;
class java_sql_Timestamp6 {
public static void main (String args[]) {
Timestamp ts=Timestamp.valueOf("1996-12-13 14:15:25.0");
System.out.println("ts = " + ts);
}
}
=== Here is the test output ===
ts = 1996-12-13 14:15:25.