update problem in stored procedure

  • i have written a stored procedure which does an update in a customer master where customerid =" so and so"

    iam calling that stored procedure from an asp page

    iam using command object

    but when i fill all the textboxes in the asp page it gets updated, but when part text boxes are filled, then sometimes it gets updated and sometimes it doesnt' any reason ??

    it has 81 fields, i tried the option of using null as default]

    by this way

    create procedure spEditCustList

    @RMCPL_CUST_CD as varchar(10),--1

    @RMCPL_TOI as varchar(70)=null, --2

    @RMCPL_CSTNO as varchar(50)=null,--3

    @RMCPL_STNO as varchar(50)=null,--4

    @RMCPL_ECCNO as varchar(50)=null,--5

    @RMCPL_FACT_ADDRESS as varchar(2000)=null,--6

    Thanks in Advance

    <a href="http://www.websolsoftware.com"> For IT jobs click here</a>

    *Sukhoi*[font="Arial Narrow"][/font]

  • This was removed by the editor as SPAM

  • What does the UPDATE command look like?

    What are the table fields/columns set as? Do the columns allow NULLs?

    -SQLBill

  • It would be helpful to see the schemea for the customer master table.  It could be that some columns are set to not allow nulls, or possibly there is a check constraint on one or more columns. 

    You should also try to trap or log the error that is returned by the ADO command object.

     

  • By default you have assigned NULL to  the perameters

    I think if some you use of these in the query for comparison with out changing their value in proceadure then these nulls would be a problem because nulls are not comparable. you try with using isnull operator for each comparison then definitly it will work.

     

    If wrong Plese write again.

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply