Articles in this section

Unable to create database from the site by a database user: Access denied for user SQL: CREATE DATABASE

Plesk for Linux kb: technical

Symptoms

  • A database user fails to create a new database from the domain code with the error:

    CONFIG_TEXT: SQLSTATE[42000]: Syntax error or access violation:
    1044 Access denied for user 'example'@'%' to database 'db-example'
    (Connection: mysql, SQL: CREATE DATABASE `db-example` CHARACTER SET `utf8` COLLATE `utf8_unicode_ci`)

Cause

By design and default security settings, database users do not have permissions to create new databases. It is expected behavior.

Resolution

Create the needed database 'db-example' from the Plesk side as described here.

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.