CLI
- Print
- DarkLight
CLI
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback!
Requirements
Jave 8
1. Download CLI
Download CLI here
Unix
./doordahost.jar \
--server https://host.doorda.com \
--user user1 \
--password \ ## Do not add your password here. You will be prompt for it
--catalog doordastats-snapshot \
--schema doordastats-snapshot
Windows
Open Powershell
java -jar c:\..\doordahost.jar \
--server https://host.doorda.com \
--user user1 \
--password \ ## Do not add your password here. You will be prompt for it
--catalog doordastats-snapshot \
--schema doordastats-snapshot
Export table to file (UNIX)
Modify username
, PRESTO_PASSWORD
, catalog
, schema
, query_string
, output_format
and output_location
cat <<EOT >> test_export.sh
#!/bin/bash
export PRESTO_PASSWORD={password}
./doordahost \ // Change path to location of cli
--server https://host.doorda.com \
--user {username}
--password \
--catalog {catalog} \
--schema {schema}
--execute "{query_string}" \
--output-format {output_format} > {output_location}
EOT
Output Options
- CSV(without header)
- TSV (without header)
- CSV_HEADER (with header)
- TSV_HEADER (with header)
- ALIGNED
- VERTICAL