|  |  | 
|  |  | Archives of the TeradataForumMessage Posted: Tue, 06 Nov 2012 @ 18:11:46 GMT
 
 < -- Anonymously Posted: Tuesday, November 06, 2012 12:32 -- > Apply an explicit FORMAT to the decimal column, before casting to CHAR. The default for DECIMAL(18,0) is FORMAT '-(18)9.' For no sign and no decimal point, something like this should work: 
     CAST(CAST(col1 as DECIMAL(18,0) FORMAT 'Z(17)9') AS char(18))
 | ||||||||||||||||||||||||||||||||||||||||||||||
|  | ||||||||||||||||||||||||||||||||||||||||||||||||
| 
 | ||||||||||||||||||||||||||||||||||||||||||||||||
|   | ||||||||||||||||||||||||||||||||||||||||||||||||
| Copyright 2016 - All Rights Reserved | ||||||||||||||||||||||||||||||||||||||||||||||||
| Last Modified: 15 Jun 2023 | ||||||||||||||||||||||||||||||||||||||||||||||||