From 3fc5f79577f52b24c924a49e06432fa48964bbdc Mon Sep 17 00:00:00 2001 From: john Date: Thu, 18 Apr 2002 08:56:45 +0000 Subject: [PATCH] got rid of use of jdbc's result_set.getTimestamp() method, which loses information which is stored by postgres replaced with ordinary result_set.getString(), which returns a compatible string to timestamp.toString(), which is what is expected(plus some extra info on the end-the worst thing that can happen is a little bit of table stretching in the admin pages) --- source/mir/storage/Database.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/source/mir/storage/Database.java b/source/mir/storage/Database.java index 43dcad90..9f56efc9 100755 --- a/source/mir/storage/Database.java +++ b/source/mir/storage/Database.java @@ -252,9 +252,13 @@ public class Database implements StorageObject { //outValue = StringUtil.encodeHtml(StringUtil.unquote(outValue)); break; case java.sql.Types.TIMESTAMP: - Timestamp timestamp = (rs.getTimestamp(valueIndex)); + //Timestamp timestamp = (rs.getTimestamp(valueIndex)); + //jbdc drops time zone info, + //so just get the string from + //postgres + String timestamp = (rs.getString(valueIndex)); if (!rs.wasNull()) { - outValue = timestamp.toString(); + outValue = timestamp; } break; default: -- 2.11.0