Home » RDBMS Server » Server Utilities » how to convert UTC timestamp to local timestamp
how to convert UTC timestamp to local timestamp [message #74555] Thu, 06 January 2005 18:05 Go to next message
how to get day in sql que
Messages: 4
Registered: January 2005
Junior Member
here is my control file
==============
LOAD DATA
INFILE 'd:jaiflatdailyFlight.txt'
INTO TABLE IK_FLIGHT_DAILY
when (62) = 'A'
(FLIGHT_NO position(16:24) CHAR,SCHEDULED_DATETIME position(34:47) DATE "yyyymmddhh24miss",
FLIGHT_ID "flightdaily_bulk_seq.nextval",
URNO POSITION(01:10) integer external,
....)

My datatype for SCHEDULED_DATETIME is DATE and its working perfectly fine.

Here is the problem
===============
GMT+07:00 = bangkok local time

example::::::20040324133000 timestamp which i am getting from flat file in UTC format, need to be converted into local time

for example i am getting 1330(UTC format), i want to add 7hrs with that time. so 1330 should be updated in the database as 2030

how do i do this in control file, or is there anyother way, pls suggest.
Re: how to convert UTC timestamp to local timestamp [message #74556 is a reply to message #74555] Thu, 06 January 2005 21:52 Go to previous messageGo to next message
Barbara Boehmer
Messages: 9097
Registered: November 2002
Location: California, USA
Senior Member
SCHEDULED_DATETIME position(34:47) "to_date (:scheduled_datetime, 'yyyymmddhh24miss') + 7/24",
Re: how to convert UTC timestamp to local timestamp [message #74557 is a reply to message #74556] Thu, 06 January 2005 22:29 Go to previous message
how to get day in sql que
Messages: 4
Registered: January 2005
Junior Member
Dear Barbara Boehmer,

Hats of to you. it works perfectly fine.

Regards
JAI
Previous Topic: How do I copy just the data from one db to another?
Next Topic: ora-01031 error in sqlplus trying startup command
Goto Forum:
  


Current Time: Wed Jul 03 17:31:25 CDT 2024