How to list all SAP HANA users with their lock status?

We want to list down all users created in SAP HANA system and we also want to know user's locked/Unlocked status.

Requirement: We want to list SAP HANA users with their lock status.
Prerequisite: We need a database user with DATA ADMIN or CATALOG READ assigned.

Steps:
  • Connect to the required system via HANA Studio
  • Open Administration perspective,  You can open it from Window -> Open -> Perspective -> Administration Console
  • Execute following SQL in SQL console:
Select * from "SYS"."USERS";  //this will list all users in HANA systems.
Select * from "SYS"."USERS" WHERE USER_DEACTIVATED='TRUE';  // This will list down the deactivated/locked users.
Select * from "SYS"."USERS" WHERE USER_DEACTIVATED='FALSE'; // This will list down the unlocked/active users.
SAP HANA List unlocked users

These queries are similar to:
Select * from "PUBLIC"."USERS";
Select * from "PUBLIC"."USERS" WHERE USER_DEACTIVATED='TRUE';
Select * from "PUBLIC"."USERS" WHERE USER_DEACTIVATED='FALSE';

Reference: https://help.sap.com/