Re: join* tables from csv

2016-10-18 Thread Alan Thompson
You may also like this answer using DataScript to solve a similar problem: http://stackoverflow.com/questions/39712460/how-to-map-different-values-from-2-sets-in-clojure-based-on-unique-value/39714081#39714081 On Tue, Oct 18, 2016 at 6:09 AM, Moe Aboulkheir wrote: > (defn join* [d1 c1 d2 c2] >

Re: join* tables from csv

2016-10-18 Thread Moe Aboulkheir
(defn join* [d1 c1 d2 c2] (clojure.set/join (into #{} d1) (into #{} d2) {c1 c2})) Or else look at the implementation of set/join. Take care, Moe On Tue, Oct 18, 2016 at 9:41 AM, wrote: > Hey guys, i'm beginner and need help. > > I have a task: > > ;; (join* (join* student-subject :student_id

join* tables from csv

2016-10-18 Thread evgeniy . kurpanov
Hey guys, i'm beginner and need help. I have a task: ;; (join* (join* student-subject :student_id student :id) :subject_id subject :id) ;; => [{:subject "Math", :subject_id 1, :surname "Ivanov", :year 1998, :student_id 1, :id 1} ;; {:subject "Math", :subject_id 1, :surname "Petrov", :year 1