Re: mysql and clojure

2017-10-20 Thread Damien Mattei
thank for your help, i had doubt about namespace but as i focused on sql i did not check it, it is just a week i use clojure, but i'm used many Scheme and LisP and Java and there is a lot of issue on stackoverflow or stackechange about clojure and mysql that are out of date and are confusing d

RE: mysql and clojure

2017-10-19 Thread Sean Corfield
I don’t know what documentation you’re working from but it looks outdated, based on your code. Have a read of http://clojure-doc.org/articles/ecosystem/java_jdbc/home.html -- that will walk you through the basics of using java.jdbc If you’re on the Clojurians Slack (signup at http://clojurians.

Re: mysql and clojure

2017-10-19 Thread Lubomir Konstantinov
Cool. You had to remove it, cause it was a leiningen dependency, not a proper :require clause - I guess I didn't pay enough attention too :) It looks like you are trying to learn by example and are skipping the basics. If you havent - this is very nice and gentle introduction that will help you

Re: mysql and clojure

2017-10-19 Thread Rostislav Svoboda
Have a look at dbcon.clj and db.clj in my https://github.com/Bost/ufo It's a rather minimal example of clojure/clojurescript + mysql 2017-10-19 15:10 GMT+02:00 Damien Mattei : > Thank Lubomir, > it works, i'm new to Clojure and did not use the name space the right way, i > had to remove [mysql/my

Re: mysql and clojure

2017-10-19 Thread Damien Mattei
Thank Lubomir, it works, i'm new to Clojure and did not use the name space the right way, i had to remove [mysql/mysql-connector-java "5.1.38"] also , do not know why... here is the working code and result: (ns jclojure.core (:gen-class) (:require [clojure.java.jdbc :as jdbc] ) ) ;(ns

Re: mysql and clojure

2017-10-19 Thread Lubomir Konstantinov
Bad case of copy pasta? You have am extra namespace definition: (ns dbns (:require [clojure.java.jdbc :as jdbc] [mysql/mysql-connector-java "5.1.38"])) You need to remove it, and move the require clause up in your ns: (ns jclojure.core (:gen-class) (:require [clojure.j