MicroStrategy ONE
Repository Commands
- \q: Quit/Exit
- \c __database__: Connect to a database
- \d __table__: Show table definition including triggers
- \d+ __table__: More detailed table definition including description and physical disk size
- \l: List databases
- \dy: List events
- \df: List functions
- \di: List indexes
- \dn: List schemas
- \dt *.*: List tables from all schemas (if *.* is omitted will only show SEARCH_PATH tables)
- \dT+: List all data types.
- \dv: List views.
- \df+ __function__ : Show function SQL code.
- \x: Pretty-format query results instead of the not-so-useful ASCII tables.
- \copy (SELECT * FROM __table_name__) TO 'file_path_and_name.csv' WITH CSV: Export a table as CSV.
User Related:
- \du: List users
- \du __username__: List a username if present.
- create role __test1__: Create a role with an existing username.
- create role __test2__ noinherit login password __passsword__;: Create a role with username and password.
- set role __test__;: Change role for current session to __test__.
- grant __test2__ to __test1__;: Allow __test1__ to set its role as __test2__.