Liking cljdoc? Tell your friends :D
Clojure only.

datahike-csv-loader.core


load-csvclj

(load-csv conn csv-file)
(load-csv conn csv-file col-schema)

Reads, parses, and loads data from CSV file named csv-file into a Datahike database via conn, with schema for the corresponding attributes optionally specified in map col-schema.

col-schema expects a set of attribute idents as the value of each key, except :ref and :tuple. Available options are:

KeyDescription
: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
:refMap of :db/valueType :db.type/ref attributes to referenced attribute idents
:tupleMap of :db/valueType :db.type/tuple attributes to constituent column names (keywordized)
Reads, parses, and loads data from CSV file named `csv-file` into a Datahike database via `conn`,
with schema for the corresponding attributes optionally specified in map `col-schema`.

`col-schema` expects a set of attribute idents as the value of each key, except `:ref` and `:tuple`.
Available options are:

| 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` attributes to referenced attribute idents
| `:tuple`            | Map of `:db/valueType` `:db.type/tuple` attributes to constituent column names (keywordized)
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close