email should not be unique

The email in user table should not be unique.

So I changed the file user.php in common/models also i changed the SignupForm.php in frontend/models and m130524_201442_init.php in console/migrations but than i get this error

Integrity constraint violation – yii\db\IntegrityException

SQLSTATE[23000]: [Microsoft][SQL Server Native Client 11.0][SQL Server]Violation of UNIQUE KEY constraint ‘UQ__user__665877D04E88ABD4’. Cannot insert duplicate key in object ‘dbo.user’. The duplicate key value is ().

The SQL being executed was: INSERT INTO user VALUES (‘test1’, ‘test@test.de’, ‘$2y$13$zV48OV5q5MpLIx/GxiRDBuKqcBRmOZITx76i24u1KwmAqFKan49QS’, ‘eY7UxwlK3wZ-PK8Ami3nUGinKFJ6GTJJ’, 1, 1, 1, GETDATE(), GETDATE())

Error Info: Array

(

[0] => 23000

[1] => 2627

[2] => [Microsoft][SQL Server Native Client 11.0][SQL Server]Violation of UNIQUE KEY constraint ‘UQ__user__665877D04E88ABD4’. Cannot insert duplicate key in object ‘dbo.user’. The duplicate key value is ().

Please can u help me

You have changed the user model and signup form. Now you have to remove unique key constraint for email from your database table.