All Products
Search
Document Center

Lindorm:CREATE USER

Last Updated:Mar 28, 2026

Creates a new user in a Lindorm instance. Run SHOW USERS to list existing users before creating a new one to avoid username conflicts.

Applicable engines and versions

EngineVersions
LindormTableAll versions
LindormTSDBAll versions

Syntax

CREATE USER [IF NOT EXISTS] user_identifier identified BY 'password';

Parameters

ParameterDescription
IF NOT EXISTSOptional. If the username already exists and IF NOT EXISTS is omitted, an error is returned. If IF NOT EXISTS is specified and the username already exists, the statement is a no-op — no user is created and no error is returned.
user_identifierThe username. Requirements: 4–15 characters; may contain letters, digits, hyphens (-), and underscores (_); cannot be a reserved word (system, anonymous, lindorm).
passwordThe user's password. Must be of type VARCHAR.

Example

Create a user named test_user with password testuserpassword. If the user already exists, the statement does nothing.

CREATE USER IF NOT EXISTS test_user identified BY 'testuserpassword';

See also