If you have dates expressed as numeric fields (e.g. 20110505) and want to convert them to dates, it is first necessary to cast the integer as a string, and then convert to a date:
select
cast(20110505 as integer) as dt_wid,
cast(dt_wid as char(8)) as dt_wid_char,
cast(dt_wid_char as date format 'YYYYMMDD'),
cast(dt_wid_char as timestamp(6) format 'YYYYMMDD')