Documentation Home
MySQL Shell for VS Code


MySQL Shell for VS Code  /  ...  /  Settings for the Extension and All Editors

Pre-General Availability: 2023-01-18

2.3.3 Settings for the Extension and All Editors

The following settings apply to the MySQL Shell for VS Code extension and its editors.

Note

Settings for MySQL Shell for VS Code are categorized under the name of the MySQL Shell GUI (Msg) repository.

Msg › Debug Log: Level

Set a different verbosity level for the communication log between the extension and the MySQL Shell. To see this log, open the OUTPUT channel MySQL Shell for VS Code. The choice of verbosity level are as follows:

  • NONE: Switch logging off.

  • ERROR: Log errors only.

  • WARNING: Log errors and warnings.

  • INFO (default): Log errors, warnings, and other normal information.

  • DEBUG: Log for problem analysis, which prints additional information.

  • DEBUG2: Not currently used.

  • DEBUG3: Use for problem analysis. Everything is printed to the logs, which may include security information such as passwords, connection tokens and so on. However, all security-relevant information is replaced with asterisk character (***). This setting level produces a large amount of output.

Msg › Editor: Db Version

The default version to be used for MySQL language support, if no version of MySQL Server is available. Otherwise, the current version is shown.

Msg › Editor: Default Db Connection

Specify the name (title) of a DB connection to be used when running embedded SQL from a standard text editor and no connection is open yet. Leave empty to select a connection.

Msg › Editor: Show Hidden

When set to true, normally invisible characters, such as spaces or tabs, are displayed.

Msg › Editor: Show Minimap

Determines if code editors should show a minimap, instead of the plain scrollbar, for better navigation.

Msg › Editor: Sql Mode

The default SQL mode to be used for MySQL language support, if the mode information is not available. Default SQL mode value is:

ONLY_FULL_GROUP_BY STRICT_TRANS_TABLES NO_ZERO_IN_DATE NO_ZERO_DATE ERROR_FOR_DIVISION_BY_ZERO NO_ENGINE_SUBSTITUTION

For additional valid values, see sql_mode.

Msg › Editor: Stop On Errors

Set to true, for the execution of scripts to stop if an error occurs. Otherwise, the script execution continues with the next statement.

Msg › Editor › Theming: Decoration Set

Select one of the sets to be used to mark code block and results in mixed language editors. The following options are available:

  • standard (default): Includes only a solid marker for editor rows.

  • alternative: Uses a hatch pattern with different colors to mark Editor contents and result areas.

Msg › Editor: Word Wrap

To determines how long lines should be wrapped automatically by the editor. The following options are available:

  • off (default): Lines are not wrapped.

  • on: Lines are wrapped at the width of the viewport.

  • wordWrapColumn: Lines are wrapped at the Word Wrap Column.

  • bounded: Lines are wrapped at the minimum of the viewport width of Word Wrap Column.

Msg › Editor: Word Wrap Column

Integer value to control the column of the editor to wrap long lines when the editor is using wordWrapColumn or bounded word wrapping. The default value is 120.

Msg › Shell: Enforce HTTPS

Enforce the use of HTTPS when connecting to MySQL Shell. Enabled by default.

Important

This extension relies on a MySQL Shell process serving its user interface and data. To protect this flow of sensitive data, it is highly recommended to use HTTPS encryption when other users have access to the machine that is running MySQL Shell. This requires MySQL Shell's rootCA.crt certificate to be installed on the machine where MySQL Shell is running. Use the Welcome Wizard to perform this task.

Later, you can find the certificate at:

  • ~/.mysqlsh-gui/plugin_data/web_certs/rootCA.crt (macOS and Linux)

  • %appdata%\MySQL\mysqlsh-gui\plugin_data\gui_plugin\web_certs\rootCA.crt (Windows)

When using a Visual Studio Code SSH-remote development session, this certificate also must be installed on your local development machine. To install the certificate:

  1. Copy the rootCA.crt certificate to the local development machine using a secure approach, such as scp.

  2. Install the certificate locally. On macOS, you can use Keychain Access to trust the certificate (see Unix: Set up a certificate for a web server supporting HTTPS running on the localhost).

  3. Restart Visual Studio Code after the installation is finished.

Always click Reload VS Code (in the setting's description) after changing this setting.

Msg › Shell: External Url

String value to specify a URL to be used to connect to a running MySQL instance. Leave empty to use an automatically launched local MySQL Shell instance. Use the Connect to External MySQL Shell Process option in the DATABASE CONNECTIONS view menu to switch between shell connections.

Msg › Shell: Show Unsecured Connection Warning

Display a warning panel when not using HTTPS to communicate with MySQL Shell. Enabled by default.

Always click Reload VS Code (in the setting's description) after changing this setting.

Msg › Shell: Use External

The Connect to External MySQL Shell Process option.

Msg › Sql: Limit Row Count

Integer value used to determine the size of one page in a result set, but has no effect if a top-level LIMIT clause is specified in the query. Set to 0 to disable auto adding a LIMIT clause and return all records as single page. The default value is 1000.

Msg › Sql: Row Packet Size

Integer value used to determine the number of result records that are returned as a single response from the backend. The default value is 1000.

Msg › Tab Position: New Connection

Where to place the new tab when opening a database connection. The following placement options are available:

  • Active (default): In the currently active Editor group.

  • Beside Right: In the editor group beside the active one.

  • Beside Bottom: In the editor group beneath the active one.

Msg › Tab Position: New Connection With Embedded Sql

Where to place the new tab when opening a MySQL Shell console. The following placement options are available:

  • Active: In the currently active editor group.

  • Beside Right: In the editor group beside the active one.

  • Beside Bottom (default): In the editor group beneath the active one.