Jasinski Technical Wiki


Home Page
All Pages

Quick Search
Advanced Search »

Contributor Links

Create a new Page
File Management
Your Profile

Other Wiki Sections



Special Registers - DB2

Modified on Tue, Jan 06, 2009, 12:50 PM by Administrator Categorized as DB2
The following special registers apply to the server where the SQL statement containing them is running.

Register Description
CURRENT SERVER the name of the server
CURRENT TIME the time from the system clock. Multiple uses of this register within the same SQL statement yield identical results
CURRENT TIMESTAMP a timestamp based on the system clock
CURRENT TIMEZONE the difference between UTC (Universal Time, Coordinated a.k.a. zulu, Greenwich Mean Time, and GMT) and the local server time, between -24 hours and +24 hours as a DECIMAL(6,0). Subtracting CURRENT TIMEZONE from a local time converts it to UTC.
CURRENT DATE the date from the system clock
USER the username under which the SQL statment is running

ScrewTurn Wiki version Some of the icons created by FamFamFam. Except where noted, all contents Copyright © 1999-2023, Patrick Jasinski.