Skip to content

Commit

Permalink
use local DBMS configuration to convert local cell content instead of…
Browse files Browse the repository at this point in the history
… remote DBMS configuration

git-svn-id: https://svn.code.sf.net/p/jailer/code/trunk@1152 3dd849cd-670e-4645-a7cd-dd197c8d0e81
  • Loading branch information
rwisser committed Feb 9, 2017
1 parent a0abba4 commit d2dd80c
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -121,14 +121,17 @@ public LocalInlineViewBuilder(String name, String columnList) {
public LocalInlineViewBuilder(String name, String columnList, boolean allUPK) {
super(localInlineViewStyle, name, localSession, columnList.split(", *"));
this.allUPK = allUPK;
this.localDBMSConfiguration = Configuration.forDbms(localSession);
}

private final boolean allUPK;
private final Configuration localDBMSConfiguration;

protected String sqlValue(ResultSet resultSet, int i) throws SQLException {
String value = cellContentConverter.toSql(cellContentConverter.getObject(resultSet, i));
if (allUPK || isUPKColumn(columnNames[i - 1])) {
value = cellContentConverter.toSql(value);
// value = cellContentConverter.toSql(value);
value = "'" + localDBMSConfiguration.convertToStringLiteral(value) + "'";
}
return value;
}
Expand Down

0 comments on commit d2dd80c

Please sign in to comment.