Article ID: 129223, created on Aug 5, 2016, last review on Aug 5, 2016

  • Applies to:
  • Operations Automation

Symptoms

A task to create a database fails with the following output:

Last execution output   MySQL API error: Can't create database 'db1322308_newdb'; database exists.

Cause

The database server already hosts a database with the same name, as a result of incomplete actions in the past:

mysql> use db1322308_newdb;
Database changed
mysql> show tables;
Empty set (0.00 sec)
mysql>

Resolution

Verify that the database is not in use and delete it from the affected database server:

mysql> drop database db1322308_newdb;
Query OK, 0 rows affected (0.00 sec)

Search Words

database exists

MySQL API error: Duplicate entry

5356b422f65bdad1c3e9edca5d74a1ae caea8340e2d186a540518d08602aa065 e12cea1d47a3125d335d68e6d4e15e07

Email subscription for changes to this article
Save as PDF