java.jdbc

Provide optional :qualifier option to better support namespaced keywords as column identifiers

Details

  • Type: Enhancement Enhancement
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Completed
  • Affects Version/s: None
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None

Description

Currently, you can pass an :identifiers function in options to a number of functions and java.jdbc calls (keyword (identifiers col-name)) to convert SQL column names into Clojure map keys. The default for :identifiers is clojure.string/lower-case.

With the increased focus on namespaced keywords in Clojure 1.9.0 (with the introduction of clojure.spec), it would be nice to have an easy way to tell these functions to produce qualified keywords. You can do that right now by specifying something like (comp #(str "foo/" %) str/lower-case) but that's ugly!

Suggestion: add optional :qualifier option that is used as the first argument in the keyword call, which defaults to nil.

Activity

Hide
Sean Corfield added a comment -

Will be in 0.6.2

Show
Sean Corfield added a comment - Will be in 0.6.2
Hide
Sean Corfield added a comment -

Releasing 0.6.2-alpha1 with this change.

Show
Sean Corfield added a comment - Releasing 0.6.2-alpha1 with this change.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: