# Using CSV.read() to import data from a data input file into a DataFrame

**URL:** https://discourse.julialang.org/t/using-csv-read-to-import-data-from-a-data-input-file-into-a-dataframe/77120
**Category:** General Usage
**Tags:** question, dataframes, csv
**Created:** [February 26, 2022, 12:54pm UTC](https://discourse.julialang.org/t/using-csv-read-to-import-data-from-a-data-input-file-into-a-dataframe/77120 "2022-02-26T12:54:33Z")
**Posts on this page:** 1
**Showing post:** 14

<div class="post-metadata">

### Author: ![lawless-m](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/lawless-m/32/30869_2.png) [@lawless-m](https://discourse.julialang.org/u/lawless-m)
#### Post date: [February 27, 2022, 4:42pm UTC](https://discourse.julialang.org/t/using-csv-read-to-import-data-from-a-data-input-file-into-a-dataframe/77120/14 "2022-02-27T16:42:40Z")

</div>

The commented code is broken, it looks like two code fragments randomly pasted together.

in addition, Data[:1] is not valid code either

what you should be getting is

```julia
julia> Data[:1]
ERROR: ArgumentError: syntax Data[column] is not supported use df[!, column] instead
...

```

---

_[View the full topic](https://discourse.julialang.org/t/using-csv-read-to-import-data-from-a-data-input-file-into-a-dataframe/77120)._
