(load-csv conn csv-file)(load-csv conn csv-file col-schema)Reads, parses, and loads data from CSV file named csv-file into the Datahike database pointed to
by conn, with schema for the corresponding attributes optionally specified in map col-schema.
Each column represents an attribute, with keywordized column name as attribute ident, or otherwise,
an element in a heterogeneous or homogeneous tuple.
col-schema expects a set of attribute idents as the value of each key, except :ref and :tuple.
Available options:
| Key | Description |
|---|---|
:unique-id | :db/unique value :db.unique/identity |
:unique-val | :db/unique value :db.unique/value |
:index | :db/index value true |
:cardinality-many | :db/cardinality value :db.cardinality/many |
:ref | Map of :db/valueType :db.type/ref attribute idents to referenced attribute idents |
:tuple | Map of :db/valueType :db.type/tuple attribute idents to constituent attribute idents |
Please see README for more detail.
Reads, parses, and loads data from CSV file named `csv-file` into the Datahike database pointed to by `conn`, with schema for the corresponding attributes optionally specified in map `col-schema`. Each column represents an attribute, with keywordized column name as attribute ident, or otherwise, an element in a heterogeneous or homogeneous tuple. `col-schema` expects a set of attribute idents as the value of each key, except `:ref` and `:tuple`. Available options: | Key | Description | |---------------------|---------------| | `:unique-id` | `:db/unique` value `:db.unique/identity` | `:unique-val` | `:db/unique` value `:db.unique/value` | `:index` | `:db/index` value `true` | `:cardinality-many` | `:db/cardinality` value `:db.cardinality/many` | `:ref` | Map of `:db/valueType` `:db.type/ref` attribute idents to referenced attribute idents | `:tuple` | Map of `:db/valueType` `:db.type/tuple` attribute idents to constituent attribute idents Please see README for more detail.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |