validate
if needed.
With Frtictionless extract
command you can extract data from a file or a dataset.
By default, it outputs metadata visually formatted:
frictionless extract tables/*.csv
─────────────────────────────────── Dataset ────────────────────────────────────
dataset
┏━━━━━━━━┳━━━━━━━┳━━━━━━━━━━━━━━━━━━━┓
┃ name ┃ type ┃ path ┃
┡━━━━━━━━╇━━━━━━━╇━━━━━━━━━━━━━━━━━━━┩
│ chunk1 │ table │ tables/chunk1.csv │
│ chunk2 │ table │ tables/chunk2.csv │
└────────┴───────┴───────────────────┘
──────────────────────────────────── Tables ────────────────────────────────────
chunk1
┏━━━━┳━━━━━━━━━┓
┃ id ┃ name ┃
┡━━━━╇━━━━━━━━━┩
│ 1 │ english │
└────┴─────────┘
chunk2
┏━━━━┳━━━━━━━━┓
┃ id ┃ name ┃
┡━━━━╇━━━━━━━━┩
│ 2 │ 中国人 │
└────┴────────┘
It's possible to output as YAML
or JSON
, for example:
frictionless extract tables/*.csv --yaml
chunk1:
- id: 1
name: english
chunk2:
- id: 2
name: 中国人