Skip to content
This repository has been archived by the owner on Apr 30, 2020. It is now read-only.

Command flynt setup createDb fails if database user already exists. #86

Open
colourgarden opened this issue Aug 30, 2018 · 0 comments
Open

Comments

@colourgarden
Copy link

When running flynt setup for an existing project, if the database user already exists then the final flynt setup createDb task fails because it can't create the user (because it already exists).

ERROR 1396 (HY000) at line 1: Operation CREATE USER failed for 'localhost'@'localhost'

Is it possible to add a check to the relevant query that checks IF NOT EXISTS before attempting to create the database user (similar to the line above)?

I already tried manually changing the command to CREATE USER IF NOT EXISTS '${answers.dbUser}'@'${answers.dbHost}' IDENTIFIED BY '${answers.dbPassword}'; but that is invalid syntax.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant