Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2009

    Unanswered: Updation problem

    Hi, im having a prb in my code i dont knw where as i run this code it doesnt gve any error but doesnt perform any action, but when i run the same query in analyzer it works , it updates the table,
    whats the prb with code or wht ?? need help pls

    string updateAsset="update hd_asset set issue='1',Qty='1' where asset_reg_no='"+ddlRegNo.SelectedItem.Text+"'";

    DataSet dsupdateAsset = dbservice.GetDataSet(CommandType.Text, updateAsset, "tblupdateasset");

  2. #2
    Join Date
    Jun 2003
    Provided Answers: 1
    Obviously the problem is in your front-end code, not your SQL code.
    Were you calling a stored procedure to do this update rather than accessing the table directly (a bad practice), the error would be simpler to track down.
    But I suspect that value being submitted as ddlRegNo.SelectedItem.Text is not what you expect it to be. Your SQL statement is extremely simple.
    If it's not practically useful, then it's practically useless.

    blindman "sqlblindman"

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts