How can I query the postgres Point type from clojureql? I wish to use the PostGIS functionality but clojureql does not seem to include this.
1 Answer
I am not an expert in clojureql, but if this syntax is correct:
(with-connection db
(with-query-results rs ["select * from blogs"]
; rs will be a sequence of maps,
; one for each record in the result set.
(dorun (map #(println (:title %)) rs))))
(taken from here)
why not trying to change the rs into:
select point[0] as x, point[1] as y from table
Will this work? I am not sure it will, but if this Clojure way of querying is simply forwarding the query to the DB "asis" you might try using as well PostGIS operators in it.
pointis implemented in standard PostgreSQL, PostGis is not involved so far. This question turned out not to be a question at all, just several misunderstandings at once.