| Archives of the TeradataForumMessage Posted: Mon, 21 Jan 2013 @ 16:52:58 GMT
 
 
  
| Subj: |  | Re: Data format issue |  |  |  | From: |  | Dieter Noeth |  
 Koushik Chandra wrote: |  | I am having data format issue. I have a table where the date column is defined as the format "yyyy/mm/dd" and when I am selecting from this
table and doing substr it is giving correct result. |  | 
 
 
 I doubt there's a need to substring a DATE, it's usually more efficient to use EXTRACT, etc. Could you show what you actually do? 
 |  | But I have complex transformation so in between I am inserting the data in a volatile temporary table where the data format is
changing to "yy/mm/dd", though in the select I have specified the format as "yyyy/mm/dd". Because of this change of format all the sub-strings are
working wrongly. |  | 
 
 
 Your system default is set to 'yy/mm/dd' (Integerdate) and the FORMAT is apparently not carried over to the Volatile Table. Changing the dateform on session level should work: 
     SET SESSION DATEFORM = ANSIDATE;
 Dieter 
 
 |