Skip to content
This repository was archived by the owner on Oct 10, 2025. It is now read-only.

Commit 9db6bb9

Browse files
committed
Fix typos and improve formatting
1 parent b347ae5 commit 9db6bb9

File tree

1 file changed

+31
-33
lines changed

1 file changed

+31
-33
lines changed

src/content/docs/cypher/query-clauses/load-from.md

Lines changed: 31 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -147,12 +147,12 @@ See the [ignoring erroneous rows section of `COPY FROM`](import#ignore-erroneous
147147
`LOAD FROM` can scan several raw or in-memory file formats, such as CSV, Parquet, Pandas, Polars, Arrow tables, and JSON.
148148

149149
### File format detection
150-
`Load from` determines the file format based on the file extension if the `file_format` option is not given. For instance, files with a `.csv` extension are automatically recognized as CSV format.
150+
`LOAD FROM` determines the file format based on the file extension if the `file_format` option is not given. For instance, files with a `.csv` extension are automatically recognized as CSV format.
151151

152152
If the file format cannot be inferred from the extension, or if you need to override the default sniffing behaviour, the `file_format` option can be used.
153153

154154
For example, to load a CSV file that has a `.tsv` extension (for tab-separated data), you must explicitly specify the file format using the `file_format` option, as shown below:
155-
```
155+
```cypher
156156
LOAD FROM 'data.tsv' (file_format='csv')
157157
RETURN *
158158
```
@@ -170,7 +170,7 @@ See the
170170
](/import/csv#ignoring-erroneous-rows) documentation pages for the `COPY FROM` file.
171171
The configurations documented in those pages can also be specified after the `LOAD FROM` statement inside `()` when scanning
172172
CSV files. For example, you can indicate that the first line should
173-
be interpreted as a header line by setting `(haders = true)` or that the CSV delimiter is '|' by setting `(DELIM="|")`.
173+
be interpreted as a header line by setting `(headers = true)` or that the CSV delimiter is '|' by setting `(DELIM="|")`.
174174
Some of these configurations are also by default [automatically detected](/import/csv#auto-detecting-configurations) by Kùzu when scanning CSV files.
175175
These configurations determine the names and data types of the
176176
variables that bind to the fields scanned from CSV files.
@@ -186,7 +186,7 @@ provide the names of the columns. The data types are always automatically inferr
186186
if `LOAD WITH HEADERS (...) FROM` is used, in which case the data types provided inside the `(...)` are used as
187187
described [above](#bound-variable-names-and-data-types)).
188188

189-
Suppose user.csv is a CSV file with the following contents:
189+
Suppose `user.csv` is a CSV file with the following contents:
190190
```
191191
name,age
192192
Adam,30
@@ -198,15 +198,14 @@ Then if you run the following query, Kùzu will infer the column names `name` an
198198

199199
```cypher
200200
LOAD FROM "user.csv" (header = true) RETURN *;
201-
-----------------
202-
| name | age |
203-
-----------------
204-
| Adam | 30 |
205-
-----------------
206-
| Karissa | 40 |
207-
-----------------
208-
| Zhang | 50 |
209-
-----------------
201+
┌─────────┬───────┐
202+
│ name │ age │
203+
│ STRING │ INT64 │
204+
├─────────┼───────┤
205+
│ Adam │ 30 │
206+
│ Karissa │ 40 │
207+
│ Zhang │ 50 │
208+
└─────────┴───────┘
210209
```
211210

212211

@@ -220,15 +219,15 @@ Zhang,50
220219

221220
```cypher
222221
LOAD FROM "user.csv" (header = false) RETURN *;
223-
---------------------
224-
| column0 | column1 |
225-
---------------------
226-
| Adam | 30 |
227-
---------------------
228-
| Karissa | 40 |
229-
---------------------
230-
| Zhang | 50 |
231-
---------------------
222+
┌─────────┬─────────┐
223+
column0 column1
224+
│ STRING │ STRING │
225+
├─────────┼─────────┤
226+
│ name │ age │
227+
│ Adam │ 30
228+
│ Karissa │ 40 │
229+
Zhang │ 50
230+
└─────────┴─────────┘
232231
```
233232

234233
### Parquet
@@ -240,15 +239,14 @@ and the same content as in the `user.csv` file above. Then the query below will
240239

241240
```cypher
242241
LOAD FROM "user.parquet" RETURN *;
243-
----------------
244-
| f0 | f1 |
245-
----------------
246-
| Adam | 30 |
247-
----------------
248-
| Karissa | 40 |
249-
----------------
250-
| Zhang | 50 |
251-
----------------
242+
┌─────────┬───────┐
243+
│ f0 │ f1 │
244+
│ STRING │ INT64 │
245+
├─────────┼───────┤
246+
│ Adam │ 30 │
247+
│ Karissa │ 40 │
248+
│ Zhang │ 50 │
249+
└─────────┴───────┘
252250
```
253251

254252
### Pandas
@@ -350,5 +348,5 @@ age: [[30,40,50]]
350348
```
351349

352350
### JSON
353-
Kùzu can scan JSON files using `LOAD FROM`.
354-
All JSON-related features are part of the JSON extension. See the documentation on the [JSON extension](/extensions/json#load-from) for details.
351+
Kùzu can scan JSON files using `LOAD FROM`, but only upon installation of the JSON extension.
352+
See the documentation on the [JSON extension](/extensions/json#load-from) for details.

0 commit comments

Comments
 (0)