Skip to content

status ​

Command: status
Category: System Admin
Status: Production Ready

Description ​

Get Connection Status and user information. This command displays the current database connection details, including the current user, current schema, session context information, granted roles, and optionally, granted privileges.

Syntax ​

bash
hana-cli status [options]

Aliases ​

  • s
  • whoami

Command Diagram ​

Parameters ​

Options ​

OptionAliasTypeDefaultDescription
--priv-p, --privilegesbooleanfalseDisplay granted privileges in addition to roles

Connection Parameters ​

OptionAliasTypeDefaultDescription
--admin-abooleanfalseConnect via admin (default-env-admin.json)
--conn-string-Connection filename to override default-env.json

Troubleshooting ​

OptionAliasTypeDefaultDescription
--disableVerbose--quietbooleanfalseDisable verbose output - removes all extra output that is only helpful to human readable interface
--debug-dbooleanfalseDebug hana-cli itself by adding output of LOTS of intermediate details

Examples ​

Basic Usage ​

bash
hana-cli status

Display current user, schema, session context, and granted roles.

View With Privileges ​

bash
hana-cli status --priv

Display connection status including all granted privileges.

Using Alias ​

bash
hana-cli whoami

Quick check of current database user using the whoami alias.

See the Commands Reference for other commands in this category.

See Also ​