Data Import
`FORMAT JSON`
When the `json` extension is installed, `FORMAT JSON` is supported for `COPY FROM`, `COPY TO`, `EXPORT DATABASE` and `IMPORT DATABASE`. See the [`COPY` statement](#docs:sql:statements:copy) and the [`IMPORT` / `EXPORT` clauses](#docs:sql:statements:export).  
By default, `COPY` expects newline-delimited JSON. If you prefer copying data to/from a JSON array, you can specify `ARRAY true`, e.g.,  
```sql
COPY (SELECT * FROM range(5)) TO 'my.json' (ARRAY true);
```  
will create the following file:  
```json
[
{"range":0},
{"range":1},
{"range":2},
{"range":3},
{"range":4}
]
```  
This can be read like so:  
```sql
CREATE TABLE test (range BIGINT);
COPY test FROM 'my.json' (ARRAY true);
```  
The format can be detected automatically the format like so:  
```sql
COPY test FROM 'my.json' (AUTO_DETECT true);
```