Home Page for the TeradataForum
 
 

 

Archives of the TeradataForum





Message Posted: Thu, 10 Apr 2008 @ 14:07:42 GMT





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




Subj:   Re: Query to identify the Decimal
 
From:   Summers, Scott



You could do some variation of this however SQL is probably not best place for this kind of error trapping IMHO.

     create table test
     ( c1 decimal(10,3));

     insert into test (0.00);
     insert into test (122.33);

     select case when c1 <> 0 then cast(c1 as float) else cast(c1+
     999999999999.9999 as smallint) end
     from test;




     
  <Prev Next>   <<First <Prev Next> Last>>  
 
 
 
 
 
 
 
 
  
 
  Top Home Join Privacy Feedback  
 
 
Copyright for the TeradataForum (TDATA-L), Manta BlueSky 
Last Modified: 01 Sep 2008