how to take 6 decimal places in sql code example Example: sql decimal to 2 places CAST(MyNumber AS NUMERIC(18,2))