Started working on a setting that forces using system default time zone instead of FreeMarker time_zone setting when dealing with java.sql.Date and java.sql.Time objects. This is neeeded as JDBC uses that too when storing date-only and time-only values in Date-s. Also some cleanup in the old date/time formatting code.