Skip to content
This repository was archived by the owner on Jan 8, 2020. It is now read-only.

Commit ea5b3e0

Browse files
committed
[CSV-140] QuoteMode.NON_NUMERIC doesn't work with CSVPrinter.printRecords(ResultSet)
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/csv/trunk@1637781 13f79535-47bb-0310-9956-ffa450edef68
1 parent 288654d commit ea5b3e0

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

src/changes/changes.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
</properties>
4040
<body>
4141
<release version="1.1" date="2014-11-dd" description="Feature and bug fix release">
42+
<action issue="CSV-140" type="fix" dev="ggregory" due-to="Damjan Jovanovic">QuoteMode.NON_NUMERIC doesn't work with CSVPrinter.printRecords(ResultSet)</action>
4243
<action issue="CSV-131" type="add" dev="ggregory" due-to="Holger Stratmann">Save positions of records to enable random access</action>
4344
<action issue="CSV-130" type="fix" dev="ggregory" due-to="Sergei Lebedev">CSVFormat#withHeader doesn't work well with #printComment, add withHeaderComments(String...)</action>
4445
<action issue="CSV-128" type="fix" dev="ggregory">CSVFormat.EXCEL should ignore empty header names</action>

src/main/java/org/apache/commons/csv/CSVPrinter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,7 @@ public void printRecords(final ResultSet resultSet) throws SQLException, IOExcep
512512
}
513513
while (resultSet.next()) {
514514
for (int i = 1; i <= columnCount; i++) {
515-
print(resultSet.getString(i));
515+
print(resultSet.getObject(i));
516516
}
517517
println();
518518
}

0 commit comments

Comments
 (0)