This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Raster File Globbing | |
COPY table FROM '/path/path/something_*.tiff' WITH (source_type='raster_file') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Using a data source name: | |
COPY example_table | |
FROM 'SELECT * FROM remote_postgres_table WHERE event_timestamp > ''2020-01-01'';' | |
WITH | |
(source_type = 'odbc', | |
sql_order_by = 'event_timestamp', | |
data_source_name = 'postgres_db_1', | |
username = 'my_username', | |
password = 'my_password'); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## access omnisql through the container | |
docker exec -it omnisciserver /omnisci/bin/omnisql -q -s omnisciserver -u myuser -p mypass --db mydb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## restart your omnisci server and web server containers | |
sudo Docker restart $(sudo docker ps -a -q) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## list your docker containers on your machine | |
sudo docker ps |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## add a unique id to your table | |
alter table table_name add column unique_id_int BIGINT; | |
update table_name | |
set unique_id_int = rowid |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## tail the logs from outside the logs directory | |
ls -rt /var/lib/omnisci/data/mapd_log/*.INFO | tail -100 | xargs tail -f |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## tail the logs from within the log directory | |
tail -f omnisci_server.INFO |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## copy files to or from your omnisci server with rsync | |
rsync -av --progress -e "ssh -i ~/.ssh/yourkey.pem" /path/to/file.csv [email protected]:~/. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## copy files to or from your omnisci server with SCP | |
scp -i /path/yourkey.pem largefile.csv my-instance-user-name@my-instance-public-dns-name:~/. |
NewerOlder