Get the App
SLTechnology News&Howtos  ›  Database  › 

Mysql modifies database information through the command line

Shulou Source: shulou.com Published: 2022-06-01 10:15:37 09月17日 Update

1. Syntax:

ALTER DATABASE database name

CHARACTER SET coding

COLLATE proofreading rules

two。 Syntax parsing:

Database name: demo1

Coding: one of the coding sets, such as utf8.

Proofreading rules: one of a set of proofreading rules, such as utf8_general_ci

3. Example:

# modify coding and proofreading rules

ALTER DATABASE demo1

CHARACTER SET utf8

COLLATE utf8_general_ci

4. Screenshot of the running result:

Tags: Proofreading coding rules data database syntax screenshots examples results runs messages commands Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Docker NVidia MySQL Huawei Xiaomi