Inserts the rows of the Incanter dataset into the given MongoDB collection.
Examples:
(use '(incanter core datasets mongodb))
(use 'somnium.congomongo)
(def data (get-dataset :airline-passengers))
(view data)
;; a MongoDB server must be running on the localhost on the default port
;; for the following steps.
(mongo! :db "mydb")
(mass-insert! :airline-data (:rows data))
;; notice that the retrieved data set has two additional columns, :_id :_ns
(view (fetch-dataset :airline-data))
Comments top
No comments for insert-dataset. Log in to add a comment.