这个返回值应该表示没有错误发生使用comm.executenoquery()可以得到返回值

解决方案 »

  1.   

    我试了很多次,凡是没有正确更新到数据库的update还回值都是0阿!!!
    不知道怎么会是-1 呢??
    请csdn的朋友指点一二??
      

  2.   

    Calls the respective INSERT, UPDATE, or DELETE statements for each inserted, updated, or deleted row in the specified DataSet.[C#]
    public override int Update(DataSet dataSet);
    Parameters
    dataSet 
    The DataSet used to update the data source. 
    Return Value
    The number of rows successfully updated from the DataSet.
      

  3.   

    多谢指点!那判断oledbdataadapter.update()是否成功,
    还不能根据还回值判断??????