Creating a Database Account
Scenarios
When you create a GaussDB(for MySQL) instance, account root is created at the same time by default. You can add other accounts as required.
Constraints
This operation is not allowed when another operation is being performed on your DB instance.
Procedure
- Log in to the management console.
- Click
in the upper left corner and select a region and a project.
- Click
in the upper left corner of the page, choose .
- On the Instances page, click the instance name to go to the Basic Information page.
- In the navigation pane on the left, choose Accounts. On the displayed page, click Create Account. In the displayed dialog box, enter a username, authorize permissions for databases, enter a password, and confirm the password. Then, click OK.
- The username can consist of 1 to 32 characters. Only lowercase letters, digits, and underscores (_) are allowed.
- You can select one or more unauthorized databases and authorize their permissions to the account. If there are no unauthorized databases, you can create ones. You can also modify the database permissions after the account is created.
If you do not delete a database on the GaussDB(for MySQL) console but delete a database in other ways, permissions granted specifically for the database are not automatically deleted. They must be deleted manually. This is an open-source MySQL behavior. For details, see DROP DATABASE Statement.
- The password can consist of 8 to 32 characters, including at least three types of the following characters: uppercase letters, lowercase letters, digits, and special characters (~!@#$%^*-_=+?,()&). It cannot be the same as the username or the username spelled backwards.
- After the account is created, you can manage it on the Accounts page of the selected instance.
Creating a Database Account Through DAS
- Log in to the management console.
- Click
in the upper left corner and select a region and a project.
- Click
in the upper left corner of the page, choose .
- On the displayed login page, enter the username and password and click Log In.
- Choose SQL Operations > SQL Query and enter the following command:
create user Account name;
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.