Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Thu, 20 Jan 2011 @ 09:09:42 GMT


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


Subj:   Re: How to Change INTEGER to DATE
 
From:   Maccha Narayana Rao Naidu

Thanks i got that.....

     (((100 * ((4 * nullifzero(abs(PasswordDate)) - 1) / 146097)
               + (4 * (((4 * abs(PasswordDate) - 1) MOD 146097) / 4) + 3)
                     / 1461 - 1900)
               + ((5 * (((4 * (((4 * abs(PasswordDate) - 1) MOD 146097)
                     / 4) + 3) MOD 1461 + 4) / 4) - 3) / 153 + 2) / 12) * 10000
               + (((5 * (((4 * (((4 * abs(PasswordDate) - 1) MOD 146097)
                     / 4) + 3) MOD 1461 + 4) / 4) - 3) / 153 + 2) MOD 12 + 1)
               * 100 + ((5 * (((4 * (((4 * abs(PasswordDate) - 1) MOD 146097)
                     / 4) + 3) MOD 1461 + 4) / 4) - 3) MOD 153 +5)
               / 5 (date, format 'yy/mm/dd'))

Thanks

Narayan.Machha
Teradata DBA
Intelligroup



     
  <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