Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Mon, 06 Apr 2009 @ 21:10:09 GMT


     
  <Prev Next>  
<<First
<Prev
Next> Last>>  


Subj:   CURRENT_TIMESTAMP not UTC
 
From:   DAVID WILLIAMS

I have a query that compares the current_timestamp between start timestamp and end timestamp

     WHERE current_timestamp
              BETWEEN DW_START_DT_TM AND DW_END_DT_TM

The timestamps DW_START_DT_TM and DW_END_DT_TM are loaded from a source that is in UTC time. The current_timestamp is in local time. I was able convert the current_timestamp by writting the query as below, however, written this way will have to be updated twice a year for daylight savings time.

     WHERE current_timestamp + interval '04:00' hour to minute
              BETWEEN DW_START_DT_TM AND DW_END_DT_TM

Is there a way to write a conversion that will not have to be updated twice a year?



     
  <Prev Next>  
<<First
<Prev
Next> Last>>  
 
 
 
 
 
 
 
 
  
  Top Home Privacy Feedback  
 
 
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 15 Jun 2023