一直都是注册失败,原因为未知错误
错误代码 sql语句错误
### Error updating database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
### The error may involve com.miaoshaproject.dao.UserDOMapper.insertSelective-Inline
### The error occurred while setting parameters
### SQL: insert into user_info
### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
<insert id="insert" parameterType="com.miaoshaproject.dataobject.UserDO"> <!-- WARNING - @mbg.generated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Wed Apr 17 16:27:48 CST 2019. --> insert into user_info (id, name, gender, age, talphone, register_mode, third_party_id) values (#{id,jdbcType=INTEGER}, #{name,jdbcType=VARCHAR}, #{gender,jdbcType=TINYINT}, #{age,jdbcType=INTEGER}, #{talphone,jdbcType=VARCHAR}, #{registerMode,jdbcType=VARCHAR}, #{thirdPartyId,jdbcType=VARCHAR}) </insert>
<insert id="insertSelective" parameterType="com.miaoshaproject.dataobject.UserDO" keyProperty="id" useGeneratedKeys="true"> <!-- WARNING - @mbg.generated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Wed Apr 17 16:27:48 CST 2019. --> insert into user_info <trim prefix="(" suffix=")" suffixOverrides=","> <if test="id != null"> id, </if> <if test="name != null"> name, </if> <if test="gender != null"> gender, </if> <if test="age != null"> age, </if> <if test="talphone != null"> talphone, </if> <if test="registerMode != null"> register_mode, </if> <if test="thirdPartyId != null"> third_party_id, </if> </trim> <trim prefix="values (" suffix=")" suffixOverrides=","> <if test="id != null"> #{id,jdbcType=INTEGER}, </if> <if test="name != null"> #{name,jdbcType=VARCHAR}, </if> <if test="gender != null"> #{gender,jdbcType=TINYINT}, </if> <if test="age != null"> #{age,jdbcType=INTEGER}, </if> <if test="talphone != null"> #{talphone,jdbcType=VARCHAR}, </if> <if test="registerMode != null"> #{registerMode,jdbcType=VARCHAR}, </if> <if test="thirdPartyId != null"> #{thirdPartyId,jdbcType=VARCHAR}, </if> </trim> </insert>
字段名都正确