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

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

@colourgarden

Description

@colourgarden

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions