- 博客(4)
- 收藏
- 关注
原创 mysql unique index 允许为null
最近遇到个问题是关于mysql 数据库 unique key 唯一约束索引添加的问题。问题场景:根据业务需要给数据库表添加一个多字段联合唯一索引 unique index。使用表的phone, shop_code 字段关联创建。其中表phone字段允许null,默认为null。操作:使用sql执行脚本执行添加索引sql。执行时报错。提示有创建唯一约束字段存在重复值。排查问题:SELECT COUNT(DISTINCT `phone`, `shop_code`) from customer;1
2020-11-07 00:56:11 3607
原创 IntelliJ IDEA git commit 时忽略文件设置
在使用idea git 提交代码是,设置忽略 .git .iml 文件以及 target 文件夹Windows:File - Settings - Editor - File TypesMac:Preferences.. - Editor - File Types 在 Ignore files and folders 里添加上想要忽略不提交的文件.iml;.idea;tar...
2018-08-05 02:37:53 5102 1
原创 IntelliJ IDEA 创建类自动生成摸板注释
IDEA 创建类时自动生成注释摸板 设置: windows:File-Settings – Editor – File and Code Templatesmac:Preferences.. – Editor – File and Code Templates在public class 上添加上: /*** ${DESCRIPTION}* @author 你自...
2018-08-05 01:37:32 412 2
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人