MyBatisPlus处理类名和表名映射的配置和方法

一.(AbCd->ab_cd)驼峰转全小写+下划线分开

mybatis-plus:

configuration:

table-underline: true

二.(AbCd->AbCd)按照类名保持不变

mybatis-plus:

configuration:

table-underline: false

三.非以上的两种情况使用@TableName("表名")

3.1 手动转为全小写

@TableName("abcd")

3.2 转为随机名字

@TableName("RandomTABleNamE")