I'm using "round" function in an SQL query to show the decimal number with 2 decimal points which is originally 4 decimal points in the database table.
Select round(price,2) From tbl_example
And this query shows up the perfect results as 50.00,55.00 & so on...when I run it on SQL server 2005 Management Express.
But when I try to copy and paste the same query in the DataSource of my GridView and test the query it just shows up all the numbers with 4 decimal points, It doesn't truncate the number to 2 decimal points for some reason.
Can you help me with this issue?
Is there any way I can store all the decimal numbers in the database table itself as 2 decimal points instead of using round function each and every time to display results?
I tried going to table design and set datatype of my decimal number to "decimal(8,2), but it just gets overwritten with "decimal" datatype...
I need help with this issue urgenty.