Skip to content
Advertisement

Tag: decimal

Insert decimal with comma is interpreted as two values

I’m creating an ssrs report and creating a mockdata sql script. In the script I want to insert a decimal value like so: The values after “someString” are actually one decimal value with a comma as decimal separator. SQL interprets this as separate values though and hence throws an error about too many values for the number of columns. How

Remove trailing zeros from decimal in SQL Server

I have a column DECIMAL(9,6) i.e. it supports values like 999,123456. But when I insert data like 123,4567 it becomes 123,456700 How to remove those zeros? Answer A decimal(9,6) stores 6 digits on the right side of the comma. Whether to display trailing zeroes or not is a formatting decision, usually implemented on the client side. But since SSMS formats

Advertisement