Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Tue, 16 Oct 2001 @ 16:41:39 GMT


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


Subj:   TIMESTAMPS from Excel
 
From:   Walt Craig

I've managed to load a CSV file via Mload, but am stumped on how to parse the timestamp that comes out of Excel. I define the timestamp as a VARTEXT column and load it into a VARCHAR on a staging table in T'data. Once in the staging table I want to reformat the date and insert the date only into the target table. The data is coming from Excel in the following format: "mm/dd/yyyy hh:mm:ss", with the data looking like: "7/10/1998 12:02:35", "10/2/1999 13:45:02", etc. I don't need the time value but that's what you get with a simple export from Excel, I can get rid of the time. I'm trying to develop something generic that will address data over which I might not have any control of the extraction/export process, leaving me with no choice but to deal with a timestamp in this format. How do I parse the date since a single digit month and/or day appears to make it impossible to use an same INDEX clause for each record. I can see how you might pull the year and maybe the month, but how do I get the day?



     
  <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: 27 Dec 2016