コード例 #1
0
ファイル: SqlResult.cs プロジェクト: huangpu/managementSystem
 public bool insertResult(ResultBean result)
 {
     sqlString = "insert into tbl_ResultData(User_ID,Project_ID,Result_BookNumber,Result_BookNameC,Result_BookNameEn,Result_class,Result_PublishName,Result_PublishLevel,Result_PublishTime,Result_publishNumber,Result_WordCount) values('" + result.UserId + "','" + result.RtProjectID + "','" + result.RtBookNumber + "','" + result.RtBookNameC + "','" + result.RtBookNameEn + "','" + result.RtClass + "','" + result.RtPublishName + "','" + result.RtPublishLevel + "','" + result.RtPublishTime + "','" + result.RtPublishNumber + "','" + result.RtWordCount + "')";
     if (db.ExecuteSQL(sqlString) != -1)
     {
         return(true);
     }
     return(false);
 }
コード例 #2
0
ファイル: SqlResult.cs プロジェクト: huangpu/managementSystem
        public bool updateResult(ResultBean result)
        {
            sqlString = "update tbl_ResultData set Result_BookNumber='" + result.RtBookNumber + "',Result_BookNameC='" + result.RtBookNameC + "',Result_BookNameEn='" + result.RtBookNameEn + "',Result_class='" + result.RtClass + "',Result_PublishName='" + result.RtPublishName + "',Result_PublishLevel='" + result.RtPublishLevel + "',Result_PublishTime='" + result.RtPublishTime + "',Result_publishNumber='" + result.RtPublishNumber + "',Result_WordCount='" + result.RtWordCount + "' where Project_ID='" + result.RtProjectID + "'";

            if (db.ExecuteSQL(sqlString) != -1)
            {
                return(true);
            }
            return(false);
        }