# ElasticSearch data to a simple file

**URL:** https://discuss.elastic.co/t/elasticsearch-data-to-a-simple-file/7885
**Category:** Elasticsearch
**Created:** [May 28, 2012, 9:16am UTC](https://discuss.elastic.co/t/elasticsearch-data-to-a-simple-file/7885 "2012-05-28T09:16:09Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Prab](https://avatars.discourse-cdn.com/v4/letter/p/d2c977/32.png) [@Prab](https://discuss.elastic.co/u/Prab)
#### Post date: [May 28, 2012, 9:16am UTC](https://discuss.elastic.co/t/elasticsearch-data-to-a-simple-file/7885/1 "2012-05-28T09:16:09Z")

</div>

Hello,

I would like to convert all data stored in ES to a simple file. Exact use  
case is,

I would be storing logs in ES with timestamp as index and when user  
triggers a file request operation it should provide a log file (in a file  
system) with all the data.

is there anyway to do this? ( i was thinking to search for \_all and parse  
the JSON and then add to a file - this is going to be a over kill)

-Prab

---

<div class="post-metadata">

### Author: ![Ivan](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Ivan](https://discuss.elastic.co/u/Ivan)
#### Post date: [May 29, 2012, 6:24pm UTC](https://discuss.elastic.co/t/elasticsearch-data-to-a-simple-file/7885/2 "2012-05-29T18:24:53Z")

</div>

It is more efficient to scan across your values:

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

However, if your data is large enough to merit use a scan, then  
perhaps it is too big to place into a file. How many documents will  
you be outputting?

--  
Ivan

On Mon, May 28, 2012 at 2:16 AM, Prab [itsmeprabhakar@gmail.com](mailto:itsmeprabhakar@gmail.com) wrote:

> Hello,
> 
> I would like to convert all data stored in ES to a simple file. Exact use  
> case is,
> 
> I would be storing logs in ES with timestamp as index and when user triggers  
> a file request operation it should provide a log file (in a file system)  
> with all the data.
> 
> is there anyway to do this? ( i was thinking to search for \_all and parse  
> the JSON and then add to a file - this is going to be a over kill)
> 
> -Prab

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [July 6, 2017, 3:26am UTC](https://discuss.elastic.co/t/elasticsearch-data-to-a-simple-file/7885/3 "2017-07-06T03:26:33Z")

</div>


