Skip to content

Instantly share code, notes, and snippets.

View edubois1976's full-sized avatar

GIEIRIS Dubois Emmanuel edubois1976

  • U GIE IRIS
View GitHub Profile
@BirgittaHauser
BirgittaHauser / Timestamp ISO8601
Created January 3, 2020 09:57
Convert a (Db2 for i) Timestamp into a character representation of a timestamp in the ISO8601 Format: YYYY-MM-DDTHH:MM:SS+/HH:MM
-- Convert a (Db2 for i) Timestamp into a character representation of a timestamp in the ISO8601 Format:
-- YYYY-MM-DDTHH:MM:SS+/HH:MM
Create Or Replace Function YOURSCHEMA.TIMESTAMP_ISO8601
(ParTimestamp Timestamp(6) Default Current_Timestamp,
ParTimeZone Decimal(6, 0) Default Current_Timezone)
Returns Varchar(26)
Language SQL
Modifies Sql Data
Specific TS_ISO8601