SQL error using FR3DLdapBundle and FOSUserBundle with Symfony 2.8

66 Views Asked by At

When I log out and try to log back in again, it gives me the same error:

(An exception occurred while executing ‘INSERT INTO fos_user (username, username_canonical, email, email_canonical, enabled, salt, password, last_login, confirmation_token, password_requested_at, roles, dn, code_utilisateur) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)’ with params [“riemann”, “riemann”, “[email protected]”, “[email protected]”, 1, null, “”, “2018-05-23 21:26:15”, null, null, “a:1:{i:0;s:9:\”ROLE_USER\”;}”, “uid=riemann,dc=example,dc=com”, null]:

SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicata du champ ‘[email protected]’ pour la clef ‘UNIQ_957A6479A0D96FBF’)

As if it is trying to insert at the places to update the user.

1

There are 1 best solutions below

0
On

You need to change the order of the chain providers.

providers: [fos_userbundle, fr3d_ldapbundle]