Reputation: 1526
I need to query the database, and drop the results in a csv file.
I remember I did this with sql server, is it possible to do this CrateDB?
Upvotes: 1
Views: 1319
Reputation: 729
CrateDB's crash
shell supports various different output formats, including csv
.
Example:
crash --format csv -c 'select * from sys.cluster' > sys_cluster.csv
See https://crate.io/docs/reference/crash for details.
Upvotes: 5
Reputation: 1071
Of course yes, where are u getting stuck?
You can find the official github repository of examples: crate/crate-sample-apps, where cratedb is used. You can use this as a baseline to understand crate.
And, you can easily convert the values from crate to a CSV format using various language specific libraries. For example, in python you can use csv.
Upvotes: 1