为什么ActiveRecord这样设置unique会出现alisa table name,导致错误? [ 2.0 版本 ]
[['username'], 'unique', 'targetClass' => '\common\models\User' ,'message' => '用户已经存在.', 'on' => ['create']],
SELECT EXISTS(SELECT * FROM `auth_user` WHERE (`0`.`username`='q'))'
teencard 补充于 2017-07-19 14:18
自动gen的sql,table怎么多出个0的别名?
共 2 个回答
teencard
注册时间:2014-11-25
最后登录:2017-09-09
在线时长:1小时12分
最后登录:2017-09-09
在线时长:1小时12分
- 粉丝0
- 金钱15
- 威望0
- 积分25