/  Yamcs CLI  /  yamcs dbshell

yamcs dbshell


yamcs dbshell [<OPTIONS>]


Launch Yamcs DB Shell.


-c <COMMAND>, --command <COMMAND>

Run a single SQL command string.

-N, --skip-column-names

Don't print column names.

-B, --batch

Print results using tab as the column seperator.

Use of this option disables interactive behavior such as prompt display or the history file.

Any binary fields are printed raw instead of in hexadecimal notation.


Display binary data using hexadecimal notation. This the default when running in interactive mode, but can be used in combination with --batch to show hexadecimal values also in batch mode.

DB Shell Commands

The shell sends each SQL statement that you issue to Yamcs. There is also a set of commands that are interpreted by dbshell itself. For a list of these, type help or h at the shell prompt:

simulator> help

List of dbshell commands:
?          (\?) Show help.
delimiter  (\d) Set statement delimiter.
edit       (\e) Edit a command with $EDITOR.
exit       (\q) Synonym for quit.
help       (\h) Display this help.
nopager    (\n) Disable pager. Results are printed to stdout.
pager      (\P) Print results to a pager.
quit       (\q) Quits the DB Shell.
rehash     (\#) Rebuild completion hash.
source     (\.) Execute an SQL script file, provided as argument.
status     (\s) Print status information.
system     (\!) Execute a system command.
use        (\u) Use another instance, provided as argument.
help [<COMMAND>], \h [<COMMAND>], ? [<COMMAND>], \? [<COMMAND>]

Display a help message listing all available commands.

If you provide an argument, the help message for that specific command is shown.

delimiter <STRING>, \d <STRING>

Change the string that separates SQL statements. Default is the semicolon character: ;.

edit, \e

Open an editor for entering the next SQL statement. This uses the editor indicated by the $EDITOR environment variable.

nopager, \n

Disable result paging. It is disabled by default.

pager, \P

Enable result paging. It is disabled by default.

quit, \q

Quits the DB Shell.

rehash, \#

Reload database objects, used for completion.

source <FILENAME>, \. <FILENAME>

Run statements from the provided file.

status, \s

Print information on the current state.

system <COMMAND>, \! <COMMAND>

Execute a local command in a subshell.


Switch the prompt to another instance.