Page tree
Skip to end of metadata
Go to start of metadata

JethroClient is a SQL command-line interface (CLI) offered by (and for) JethroServer. To run it, use the following command:

JethroClient instance_name connection_string -p password {options}

Connection String

The connection string is a list of one or more JethroServer network addresses, specified as host:port pairs. When specifying multiple JethroServer network addresses, they need to be separated by a semi-colon - and the entire connection string needs to be quoted (Specifying multiple addresses automatically enables client-side load balancing).

For example:

JethroClient demo localhost:9111 -p jethro

Or, if connecting to more than one host:

JethroClient demo ";" -p jethro

Command options

-i <file>Execute all SQL queries provided in an input file (SQL delimiter is ;)
-o <file>Stores all output results into a specified file
-q <query>Execute a provided text query and exit
-u <user>User name (if not provided, user 'jethro' is assumed)
-p <password>Password
-cSwitch to CSV output mode
-d <char>

For CSV mode, change the columns delimiter to a specified character (Default is <,>)

--quietSuppress all informational messages
--no_headerDon't print result set header


JethroClient myinstance -u myuser -p mypass --quiet --no_header -q "select now();"
JethroClient demo localhost:9112 -p jethro -i db_test.sql -c -d '|' > db_test.csv
JethroClient demo localhost:9112 -p jethro -i db_test.sql -c -d '|' -o db_test.csv
  • No labels