Decimal Formatting In Sql Query
I have a query as below: Select price from myTable; This returns value '22.50' However, I need the format as 5.8 bytes in my program. That is my String value should be '00022.5000
Solution 1:
From docs, I think you want CHAR( DECIMAL( 22.50, 13, 8 ) )
I have no DB2 instance to play with so can't verify. These functions are not ANSI SQL, they are DB2 specific.
Post a Comment for "Decimal Formatting In Sql Query"