예제 #1
0
        public int insertPlayerInfoEntity(DBOperation dbOperation)
        {
            int retCode = 0;

            try
            {
                string sqlstr = "insert into player_info values('" + this.openid + "'," + this.score_self + "," + this.score + "," + this.selected_car_color
                                + "," + this.shared + ",'" + this.start_time + "'," + this.status + ")";
                dbOperation.executeSqlStr(sqlstr);
            }
            catch (Exception)
            {
                retCode = -1;
            }
            return(retCode);
        }
예제 #2
0
        public int insertUserInfo(DBOperation dbOperation)
        {
            int retCode = 0;

            try
            {
                string sqlstr = "insert into user_info (openid,nickname,img_url) values ('" + this.Openid + "','" + this.Nickname + "','" + this.HeadImgUrl + "')";
                dbOperation.executeSqlStr(sqlstr);
            }
            catch (Exception)
            {
                retCode = -1;
            }

            return(retCode);
        }