I want the out as above for the specified Input.
I have tried with FORMAT'Z(20)9' but I am able to remove . (DOT) for the decimal data type.
sel CAST(CAST(123.23 AS CHAR(20)) AS DECIMAL(18,0) FORMAT'Z(20)9') as Amt
sel CAST(CAST(123.00 AS CHAR(20)) AS DECIMAL(18,0) FORMAT'Z(20)9') as Amt
getting 123 for both Queries.
Please help me with the SQL.