MySQL Workbench Manual  /  Installation  /  Command-line options

2.2 Command-line options

In addition to platform-specific command-line options, MySQL Workbench has the following command-line options:


On Microsoft Windows, the command-line options contain one leading dash instead of two. For example, use -log-level for Microsoft Windows and --log-level for Linux and OS X.

  • --log-level level: Controls the verbosity level for logging output from Workbench.

    With increasingly levels of verbosity, the valid values for level are: error, warning, info, debug1, debug2, and debug3.

    The location of the generated log files, such as wb.log, are as follows:

    Table 2.1 The default location of generated MySQL Workbench log files

    PlatformDefault location
    OS X~/Library/Application Support/Workbench/log/
    Microsoft WindowsC:\Users\user_nameAppData\Roaming\MySQL\Workbench\log\

  • --admin instance: Open an administration tab to the named MySQL instance.

  • --upgrade-mysql-dbs: Open the Migration Wizard tab.

  • --migration: Open the Migration Wizard tab.

  • --log-to-stderr: Also log to stderr.

  • --version: Show MySQL Workbench version number and exit.

  • --verbose, -v: Enable diagnostics output.

  • --query [connection|connection_string]:

    • Empty: Open a query tab and prompts for a connection.

    • Connection: Open a named connection.

    • Connection_string: Create a connection based on the entered connection string, which should be in the form $USER@$HOST:$PORT.

  • --model modelfile: open the given EER model file.

  • --script script: Open the given SQL file in a connection, typically used with the --query parameter.

  • --run code: Execute the given code using the default language for GRT shell.

  • --run-python script: Execute the given code in Python.

  • --run-script file: Execute Python code from a file.

  • --open file: Open the given file at startup. Deprecated, so instead use specific types such as --script or --model.

  • --quit-when-done: Quits MySQL Workbench after --script or --run finishes.

Download this Manual
PDF (US Ltr) - 14.7Mb
PDF (A4) - 14.7Mb
EPUB - 12.8Mb
HTML Download (TGZ) - 12.7Mb
HTML Download (Zip) - 12.8Mb
User Comments
Sign Up Login You must be logged in to post a comment.