mirror of
https://github.com/simonw/sqlite-utils.git
synced 2026-07-27 19:34:32 +02:00
sqlite-utils insert ... --nl option, closes #6
This commit is contained in:
parent
57fc8ce55e
commit
5309c5c775
3 changed files with 29 additions and 7 deletions
|
|
@ -123,6 +123,11 @@ You can import all three records into an automatically created ``dogs`` table an
|
|||
|
||||
$ sqlite-utils insert dogs.db dogs dogs.json --pk=id
|
||||
|
||||
You can also import newline-delimited JSON using the ``--nl`` option. Since [Datasette](https://datasette.readthedocs.io/) can export newline-delimited JSON, you can combine the two tools like so::
|
||||
|
||||
$ curl -L "https://latest.datasette.io/fixtures/facetable.json?_shape=array&_nl=on" \
|
||||
| sqlite-utils insert nl-demo.db facetable - --pk=id --nl
|
||||
|
||||
Upserting data
|
||||
==============
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue