You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
es2csv is a library written in python which provides command line utility to export documents based on query from elasticsearch to csv.
created
2019-08-19
updated
2019-08-19
es2csv is a library written in python which provides command line utility to export documents based on query from elasticsearch to csv.
Installation
pip install git+https://github.com/taraslayshchuk/es2csv.git #install from git source
pip install es2csv #install using pip
Query and save results to file
es2csv -q 'company: volkswagen' -o cars.csv #documents matching query string will be saved to cars.csv file
Export required fields
es2csv -f model releaseYear mileage -q 'company: volkswagen' -o cars.csv #only specified fields like model,releaseYear and mileage will be saved to file
Authorization
es2csv -a username:password -u http://onecompiler:9001/cars/ -q 'company: volkswagen' -o cars.csv