# How to ingest multiple files

**URL:** <https://discuss.elastic.co/t/how-to-ingest-multiple-files/131615>\
**Category:** Logstash\
**Created:** [May 13, 2018, 12:31pm UTC](https://discuss.elastic.co/t/how-to-ingest-multiple-files/131615 "2018-05-13T12:31:32Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![akml\_kk](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/akml_kk/32/31069_2.png) [@akml\_kk](https://discuss.elastic.co/u/akml_kk)\
**Post date:** [May 13, 2018, 12:31pm UTC](https://discuss.elastic.co/t/how-to-ingest-multiple-files/131615/1 "2018-05-13T12:31:32Z")

</div>

Hello, I need to ingest multiple files with the same categorty in the {index, document\_type}  
so i tried to use "\*" to do that but it dosen't work (the pipline is runinng but it dosen't ingest the data).  
this is my configuration file:

```
input{
 file{
path=>"C:\Users\Ahmed\Desktop\ElasticSearch\cabs_trajectories\green\green_tripdata_2013-*.csv"
            start_position=>"beginning"
             sincedb_path=>NUL
         }
}
filter{
    csv{
          separator=>","
          columns=>["VendorID","lpep_pickup_datetime","Lpep_dropoff_datetime","Store_and_fwd_flag","RateCodeID","Pickup_longitude","Pickup_latitude","Dropoff_longitude","Dropoff_latitude","Passenger_count","Trip_distance","Fare_amount","Extra","MTA_tax","Tip_amount","Tolls_amount","Ehail_fee","Total_amount","Payment_type","Trip_type"]  

       }
     mutate{
     convert=>["Pickup_latitude","float"]
 convert=>["Pickup_longitude","float"]  
 convert=>["Dropoff_latitude","float"]
 convert=>["Dropoff_longitude","float"]
 
 }      
 mutate{
 rename=>["Pickup_latitude","Pickup_location[lat]"]
 rename=>["Pickup_longitude","Pickup_location[lon]"]
 rename=>["Dropoff_latitude","Dropoff_location[lat]"]
 rename=>["Dropoff_longitude","Dropoff_location[lon]"]
 }
 date{ 
  match=>["lpep_pickup_datetime","MM/dd/yyyy HH:mm"]
  target=>"PickupDate"  
  }
}

output{ 
elasticsearch {
   hosts=> "localhost"
   index=> "cabs_pick"
   document_type=>"traj2013"
 }        
 stdout{codec=>rubydebug}
}
```

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [May 13, 2018, 8:01pm UTC](https://discuss.elastic.co/t/how-to-ingest-multiple-files/131615/2 "2018-05-13T20:01:53Z")

</div>

I believe you need to use forward slashes in your filename pattern, not backslashes.

---

<div class="post-metadata">

**Author:** ![akml\_kk](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/akml_kk/32/31069_2.png) [@akml\_kk](https://discuss.elastic.co/u/akml_kk)\
**Post date:** [May 13, 2018, 11:11pm UTC](https://discuss.elastic.co/t/how-to-ingest-multiple-files/131615/3 "2018-05-13T23:11:27Z")

</div>

i didn't know why this happened , it works with one file with \ !.

---

<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:** [June 10, 2018, 11:11pm UTC](https://discuss.elastic.co/t/how-to-ingest-multiple-files/131615/4 "2018-06-10T23:11:32Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
