changing date from EST to GMT in sqlldr script
my flatfile date looks like this: 2002/01/01 00
it is currently in EST time.
I need to load it as GMT time.
Since GMT never has daylight-savings, it is not as easy as just adding 5 hours (could be 4 or 5 hours).
I wanted to use the NEW_TIME function in my control file to do this.
My old control file to just load the date is (edited meaningless params):
( SKIP = 1,
INTO TABLE temp_weather_data
FIELDS TERMINATED BY '\t'
RDNG_DT DATE 'yyyy/mm/dd HH24',
TEMP_NBR integer external
I tried editing the date line to look like this:
RDNG_DT new_time(DATE 'yyyy/mm/dd HH24',EST, GMT),
any suggestions? that didn't work above to change to GMT
I just figured out that I still need to account for Daylight savings time (EST or EDT) so it all amounts to nothing.
Unless someone has an idea of an easy way to convert to GMT accounting for Daylight Savings I'll just hardcode the dates into a PROC and have the proc manually edit the fields.
Have you considered using TIMESTAMP WITH TIME ZONE?
"A common mistake that people make when trying to design something completely
foolproof is to underestimate the ingenuity of complete fools" - Douglas Adams
Click Here to Expand Forum to Full Width