日期:2014-05-16 浏览次数:20416 次
<?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> <!-- JDBC jar,绝对位置 或 相对位置--> <classPathEntry location="C:\Java\Libs\sqljdbc4.jar" /> <context id="SQLTables" targetRuntime="MyBatis3"> <commentGenerator> <property name="suppressDate" value="true" /> </commentGenerator> <jdbcConnection driverClass="com.microsoft.sqlserver.jdbc.SQLServerDriver" connectionURL="jdbc:sqlserver://127.0.0.1:1433;DatabaseName=aps" userId="aps" password="aps" /> <javaTypeResolver> <property name="forceBigDecimals" value="false" /> </javaTypeResolver> <!-- targetProject 指定生成文件的位置 --> <!-- targetPackage ,在指定的targetProject下,生成java包, java,XML 代码也属于包下。 --> <javaModelGenerator targetPackage="com.test.model" targetProject="src/java"> <property name="enableSubPackages" value="true" /> <property name="trimStrings" value="true" /> </javaModelGenerator> <sqlMapGenerator targetPackage="com.test.dao" targetProject="src/java"> <property name="enableSubPackages" value="true" /> </sqlMapGenerator> <javaClientGenerator type="XMLMAPPER" targetPackage="com.test.dao" targetProject="src/java"> <property name="enableSubPackages" value="true" /> </javaClientGenerator> <table tableName="TBO_ACCTINFO" > </table> <table tableName="TBO_PAOD_CARD"> </table> <table tableName="T_CARD" > </table> </context> </generatorConfiguration>