Would someone mind posting an example of a parameterized query using
clojure.contrib.sql? There are examples in the source of non-
parameterized queries, and do-prepared is used to parameterize values
for inserts, but I can't seem to get my form quite right for a query.
thanks,
Greg
--~--~---
I couldn't figure out how to do this with the included functions/
macros in clojure.contrib.sql so I massaged with-results and do-
prepared together to get this macro (with supporting fn), which seems
to work. Useful addition for contrib.sql?
;; query-with-results should work just like with-resul
On Jan 12, 2009, at 4:57 PM, Greg Harman wrote:
I couldn't figure out how to do this with the included functions/
macros in clojure.contrib.sql so I massaged with-results and do-
prepared together to get this macro (with supporting fn), which seems
to work. Useful addition for contrib.sql?
Hi
Steve,
Thanks much for your work. The new with-query-results seems to work
quite well.
Your timing is impeccable with this set of changes: I had just
finished hacking out a (much uglier) version of update-values as well.
(I'll switch over to using the clojure.contrib.sql versions now for a
numbe
On Jan 14, 2009, at 1:26 PM, Greg Harman wrote:
Thanks much for your work. The new with-query-results seems to work
quite well.
You're quite welcome. I'm glad to hear it!
Your timing is impeccable with this set of changes: I had just
finished hacking out a (much uglier) version of update-va
You're my personal Santa Claus today! :-)
Confirmed present and working for both insert and update, using a 2
field where clause.
On Jan 14, 5:14 pm, "Stephen C. Gilardi" wrote:
> I've added update-or-insert-values. I'd appreciate hearing how it
> works for you.
--~--~-~--~~
I've put together two functions that handle this for me, and although
I haven't looked at recent changes to clojure.contrib.sql (which sound
interesting), perhaps there might be some interest in what I've got.
The first function takes a database connection and a SELECT statement,
returning a func