MyatisGenerator(Mysql 8)

链接:https://pan.baidu.com/s/1g_xAgzv_ROK59SRSxcGICA
提取码:d247
在这里插入图片描述

效果
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
代码:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE generatorConfiguration
  PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN"
  "http://mybatis.org/dtd/mybatis-generator-config_1_0.dtd">
<generatorConfiguration>

	<classPathEntry	location="mysql-connector-java-8.0.20.jar"/>
	<context id="DB2Tables"	targetRuntime="MyBatis3">
 <commentGenerator> 

                <property name="suppressAllComments" value="true" /> 

            </commentGenerator>  
		<jdbcConnection driverClass="com.mysql.cj.jdbc.Driver" connectionURL="jdbc:mysql://localhost:3306/vhr?useUnicode=true&amp;characterEncoding=utf-8&amp;" userId="root" password="yangzhi">

			  <!--MySQL 8.x 需要指定服务器的时区-->
            <property name="serverTimezone" value="UTC"/>
            <!--MySQL 不支持 schema 或者 catalog 所以需要添加这个-->
            <!--参考 : http://www.mybatis.org/generator/usage/mysql.html-->
            <property name="nullCatalogMeansCurrent" value="true"/>
            <!-- MySQL8默认启用 SSL ,不关闭会有警告-->
            <property name="useSSL" value="false"/>
		</jdbcConnection>

		<javaTypeResolver>
			<property name="forceBigDecimals" value="false"/>
		</javaTypeResolver>

		<javaModelGenerator targetPackage="com.yzq.vuehrserver.bean" targetProject="src">
			<property name="enableSubPackages" value="true"/>
			<property name="trimStrings" value="true"/>
		</javaModelGenerator>

		<sqlMapGenerator targetPackage="com.yzq.vuehrserver.mapper" targetProject="src">
			<property name="enableSubPackages" value="true"/>
		</sqlMapGenerator>

		<javaClientGenerator type="XMLMAPPER" targetPackage="com.yzq.vuehrserver.mapper" targetProject="src">
			<property name="enableSubPackages" value="true"/>
		</javaClientGenerator>
		
		<table tableName="adjustsalary" domainObjectName="AdjustSalary" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="appraise" domainObjectName="Appraise" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="department" domainObjectName="Department" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="employee" domainObjectName="Employee" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="employeeec" domainObjectName="Employeeec" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="employeeremove" domainObjectName="Employeeremove" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="employeetrain" domainObjectName="Employeetrain" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="empsalary" domainObjectName="EmpSalary" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="hr" domainObjectName="Hr" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="hr_role" domainObjectName="HrRole" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="joblevel" domainObjectName="JObLevel" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="menu" domainObjectName="Menu" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="menu_role" domainObjectName="MenuRole" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="msgcontent" domainObjectName="MsgContent" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="nation" domainObjectName="Nation" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="oplog" domainObjectName="OpLog" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="politicsstatus" domainObjectName="Politicsstatus" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		
		<table tableName="position" domainObjectName="Position" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		
		<table tableName="role" domainObjectName="Role" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="salary" domainObjectName="Salary" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
		
		<table tableName="sysmsg" domainObjectName="SysMsg" enableCountByExample="false" enableUpdateByExample="false" enableDeleteByExample="false"
		enableSelectByExample="false" selectByExampleQueryId="false"></table>
	</context>
</generatorConfiguration>

参考:
MyBatis Generator 生成器把其他数据库的同名表生成下来的问题

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值