inserting decimal value using stored procedure

I am adding a decimal value using stored procedure. But when I am checking the database its rounding up. The details are below<BR><BR>1. Field Name - cl_fees, Type - Decimal (9)<BR>2. StoredProcedure<BR><BR>CREATE Procedure AddClient<BR> (<BR> @cl_name nvarchar(50),<BR> @cl_add nvarchar(255),<BR> @curr_id bigint,<BR> @cl_fees decimal(9),<BR> @cl_cont nvarchar(50),<BR> @cl_id int OUTPUT<BR> )<BR> AS<BR><BR> INSERT INTO clients<BR> (<BR> cl_name,<BR> cl_add,<BR> curr_id,<BR> cl_fees,<BR> cl_cont<BR> <BR> )<BR><BR> VALUES<BR> (<BR> @cl_name,<BR> @cl_add,<BR> @curr_id,<BR> @cl_fees,<BR> @cl_cont<BR> )<BR><BR> SELECT<BR> @cl_id = @@Identity<BR>GO<BR><BR>3. My Add.vb FIles (compiled to dll)<BR>...<BR>Public Sub UpdateClient(ByVal cl_id As Integer, ByVal cl_name As String, ByVal cl_add As String, ByVal curr_id As Integer, ByVal cl_fees As Decimal, ByVal cl_cont As String)<BR>....<BR>Dim parameterClfees As New SqlParameter("@cl_fees", SqlDbType.Decimal, 9)<BR>parameterClfees.Value = http://aspmessageboard.com/archive/index.php/cl_fees<BR>myCommand.Parameters.Add(parameterClfees)<BR>...<BR><BR>If you need any other codes I can present it<BR><BR>Thanx<BR>Nash<BR>I think it is the precision in the database. Make that higher.
 
Back
Top