Hello Seem to be a hardest word

Just another WordPress.com weblog

PreparedStatement.setTimestamp(1,datetime)

Trong sqlserver có 1 cột DateTime

Trong java nếu dùng preparedStatement rồi thiết lập giá trị cho tham số cho field dateTime này thì nên dùng setTimestamp method.

Ví dụ:
// xem ky hai dong nay
java.sql.Timestamp tstamp = new java.sql.Timestamp(00-00-00);
ps.setTimestamp(5,tstamp.valueOf(“1986-04-02 00:00:00.0″));
Đọc tiếp »

Tháng Tư 7, 2008 Đăng bởi fate | JDBC | | No Comments Yet

ButtonPanel utility

Tháng Tư 7, 2008 Đăng bởi fate | J2SE | | No Comments Yet