Mybatis逆向工程生成tinyint 转 Integer

配置需要生成的表的时候添加columnOverride 指定javaType

 <table tableName="activity_base" domainObjectName="ActivityBaseDO">
                  <generatedKey column="activity_id" sqlStatement="Mysql" identity="true"/>
                  <columnOverride column="status" javaType="Integer"/>
                   <columnOverride column="page_type" javaType="Integer"/>
                   <ignoreColumn column="created_time"/>
                  <ignoreColumn column="modified_time"/>
 table>

你可能感兴趣的:(Mysql,mybatis)