Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Mon, 16 Feb 2015 @ 09:35:02 GMT


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


Subj:   Re: Casting to integer with ** operator resulting incorrect
 
From:   Shada, Santhosh Reddy

Exponentiation is a floating point operation which produces an inexact result.

In order to avoid systematic inaccuracies, sometimes it produces a number greater than the exact result, sometimes less than the exact result. The conversion from float to integer is dictated by the SQL standard to be a truncation operation. When the inexact result is less than the exact integer

result, this truncation produces an unexpected result. However, this is the logical result of providing accuracy and confomance to the standard.


Thanks,

Santosh



     
  <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: 23 Jun 2019