CREATE ORGANIZATION USER

statementsupportedAccounts, users, sessions, warehousesEnterprise+

docs.snowflake.com ↗

Object: ORGANIZATION USER

Creates a new organization user. Organization users and organization user groups require Enterprise Edition. To inquire about upgrading, please contact Snowflake Support.

Syntax

supportedpartialnot supportednot scored

CREATE ORGANIZATION USER [ IF NOT EXISTS ] <name>
  [ objectProperties ]

Where

objectProperties ::=
  EMAIL = '<string>'
  LOGIN_NAME = '<string>'
  DISPLAY_NAME = '<string>'
  FIRST_NAME = '<string>'
  MIDDLE_NAME = '<string>'
  LAST_NAME = '<string>'
  TYPE = { PERSON | SERVICE }
  COMMENT = '<string>'

Parameters

NameRequiredDescription
namerequiredIdentifier for the organization user; must be unique for your organization. The identifier must start with an alphabetic character and cannot contain spaces or special characters unless the entire identifier string is enclosed in double quotes (for example, "My object"). Identifiers enclosed in double quotes are also case sensitive. For more information, see Identifier requirements.
EMAIL = 'string'requiredEmail address of the user.
LOGIN_NAME = 'string'optionalName that the user enters to log into the system. Login names for users must be unique across your entire organization. It cannot match the login name in a regular account that tries to import the organization user. A login name can be any string, including spaces and non-alphanumeric characters, such as exclamation points (!), percent signs (%), and asterisks (*); however, if the string contains spaces or non-alphanumeric characters, it must be enclosed in single or double quotes. Login names are always case insensitive. Snowflake allows specifying different user and login names to enable using common identifiers (for example, email addresses) for login. Default: User’s name/identifier (that is, if no value is specified, the value specified for name is used as the login name)
DISPLAY_NAME = 'string'optionalName displayed for the user in the Snowflake web interface. Default: User’s name/identifier (that is, if no value is specified, the value specified for name is used as the display name)
FIRST_NAME = 'string' , MIDDLE_NAME = string , LAST_NAME = 'string'optionalFirst, middle, and last name of the user. If the organization user is a SERVICE user, Snowflake doesn’t apply these properties to the corresponding user objects in regular accounts, because a SERVICE user can’t have them. Default: NULL
TYPE = { PERSON | SERVICE }optionalSpecifies whether the organization user represents a person or a service. For the characteristics of each type of user, including the authentication methods that a service user can use, see Types of users. PERSON and SERVICE are the only types that an organization user can have. Types that are valid for a user in a regular account but not for an organization user, such as SERVICE_AGENT and LEGACY_SERVICE, are rejected. The type determines which existing users the organization user can be linked to, and is applied to the user objects that Snowflake creates when the organization user is imported into a regular account. For more information, see Organization user types. To change the type after you create the organization user, use the ALTER ORGANIZATION USER command. Changing the type of the organization user also changes the type of the corresponding user objects in the regular accounts that imported the organization user. Default: PERSON
  • PERSON — Organization user is a human user who can interact with Snowflake.
  • SERVICE — Organization user is a service or application that interacts with Snowflake without human interaction.
COMMENT = 'string'optionalDescription of the user.

Access control requirements

A role used to execute this operation must have the following privileges at a minimum: Privilege | Object | Notes CREATE ORGANIZATION USER | ACCOUNT | By default, only the GLOBALORGADMIN and USERADMIN system roles in the organization account have this privilege. For instructions on creating a custom role with a specified set of privileges, see Creating custom roles. For general information about roles and privilege grants for performing SQL actions on securable objects, see Overview of Access Control.

See also

Referenced by