<< Back to previous view

[JDBC-9] Solve duplicate column label issue Created: 10/Jun/11  Updated: 11/Oct/11  Resolved: 11/Oct/11

Status: Resolved
Project: java.jdbc
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Enhancement Priority: Major
Reporter: Sean Corfield Assignee: Sean Corfield
Resolution: Completed Votes: 0
Labels: None


 Description   

Per Peter Siewart (and others):

– While working with clojure.java.jdbc, I kept running into the "ResultSet must have unique column labels" exception, so I rewrote it to automatically rename duplicate columns. Now, I can run "SELECT * FROM tbl1 JOIN tbl2 ON tbl1.id = tbl2.id" without causing any errors.

This would definitely be a nice enhancement but so far no one with a signed CA has offered a patch

Figuring out the appropriate renaming strategy is key - a sensible default with an optional function to allow users to specify how to do this? Or perhaps only renaming if users specify such a function?



 Comments   
Comment by Sean Corfield [ 11/Oct/11 4:12 PM ]

Applied a variant of Peter's patch and added unit tests.

Generated at Wed Jul 23 21:01:29 CDT 2014 using JIRA 4.4#649-r158309.