0

Please help me on this, after an change of domain hosting, we are getting this error in the logs when we want to create a new customer.

Start:

{"time":"2022-11-25T08:21:27+00:00", "remote_addr":"149.143.40.237", "remote_user":"", "host":"www.hydroseals.nl", "request":"POST /account/register HTTP/2.0", "status":"500", "body_bytes_sent":"93913", "referer":"https://www.hydroseals.nl/account/login", "user_agent":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36", "request_time":"0.406", "handler":"phpfpm", "country":"US", "server_name":"www.hydroseals.nl", "port":"443", "ssl_cipher":"TLS_AES_256_GCM_SHA384", "ssl_protocol":"TLSv1.3"}

Event:

[2022-11-25T08:23:11.598982+00:00] request.CRITICAL: Uncaught PHP Exception Doctrine\DBAL\Exception\DriverException: "An exception occurred while executing 'INSERT INTO `customer_address` (`id`, `customer_id`, `country_id`, `salutation_id`, `first_name`, `last_name`, `zipcode`, `city`, `street`, `created_at`) VALUES ('G�\0Â?M»�h��\"R','[�(F�L�v��*

                                                             e','���XM�@��i��>G�','9\0\nL�vD:��#�-)3�','Tim','van Dijk','3911JB','Rhenen','Herenstraat 49A','2022-11-25 08:23:11.590');':  SQLSTATE[HY000]: General error: 1449 The user specified as a definer ('o9214241'@'%') does not exist" at /data/web/application/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php line 128 {"exception":"[object] (Doctrine\\DBAL\\Exception\\DriverException(code: 0): An exception occurred while executing 'INSERT INTO `customer_address` (`id`, `customer_id`, `country_id`, `salutation_id`, `first_name`, `last_name`, `zipcode`, `city`, `street`, `created_at`) VALUES ('G�\\0Â?M»�h��\\\"R','[�\u0006(F�L��\u0002v��*\fe','��XM�@��\u001di��>G�','9\\0\\nL�vD:��#�-)3�','Tim','van Dijk','3911JB','Rhenen','Herenstraat 49A','2022-11-25 08:23:11.590');':\n\nSQLSTATE[HY000]: General error: 1449 The user specified as a definer ('o9214241'@'%') does not exist at /data/web/application/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php:128)\n[previous exception] [object] (Doctrine\\DBAL\\Driver\\PDO\\Exception(code: HY000): SQLSTATE[HY000]: General error: 1449 The user specified as a definer ('o9214241'@'%') does not exist at /data/web/application/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDO/Exception.php:18)\n[previous exception] [object] (PDOException(code: HY000): SQLSTATE[HY000]: General error: 1449 The user specified as a definer ('o9214241'@'%') does not exist at /data/web/application/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:55)"} []


Does anyone have an idea because now we cannot create new customers in the backend nor in the frontend ofcourse.

Thanks

pim

See what the isseu was, and locate the problem.

but i am unable to solved it.

pim krook
  • 41
  • 3

3 Answers3

1

The error messages indicates that something is wrong with your SQL permissions. It is not shopware specific error, you should debug your MySQL settings, maybe searching for the SQL error message will give you more information.

j_elfering
  • 2,707
  • 6
  • 15
1

As @j_elfering already noted this is not an issue with Shopware. As the message says, the user specified as definer for the database does not exist.

You can change the definer to a valid user:

UPDATE mysql.proc SET definer = 'existing_user@localhost' WHERE db = 'database_name';
dneustadt
  • 12,015
  • 1
  • 12
  • 18
0

One addition: In addition to changes in the hosting, this often also happens when a database is exported from one system using a simple mysqldump and imported to another system (for example a developer's machine). Often the original definer-users are not available on the target system on lead to errors with stored procedures and views.

There are different methods to remove the definer from a dump file before importing.

We usually create such dumps using GDPR dump which also has a skip-definer option.

Alex
  • 32,506
  • 16
  • 106
  • 171