Hi, as Derby currently does not support timezone aware date/time data types, my application that can run in local/embedded data base mode but also in networked/network server mode needs to convert input dates into UTC before storing (and back to local timezone if wanted when displaying stored information). As a start I have written a stored function accepting a timestamp and a timzone id that currently does the conversion. When running in network server mode the timezone to pass to the function is clear, but in embedded mode the 'database server' timezone depends on the user timezone.
embedded data base mode: ======================== How would I determine the timezone e.g. 'current_timestamp' function is refering to? Is there a function available for this? Would I need to write a java stored procedure using java.util.TimeZone.getDefault() for this? network server mode: ==================== Although I know the timezone when running in network server mode (and could sort of "hard code" it by putting the ID on a static data table), would there be a more elegant way of retrieving the timezone in this scenario as well? (maybe asystem property?) Thanks
