Skip to content

Commit

Permalink
Merge branch '3.10' of https://github.com/JumpMind/symmetric-ds.git i…
Browse files Browse the repository at this point in the history
…nto 3.10
  • Loading branch information
jaredfrees committed May 15, 2019
2 parents 46ec1e3 + 66c675a commit 17a39bc
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
Expand Up @@ -82,6 +82,7 @@ public Set<String> routeToNodes(SimpleRouterContext routingContext, DataMetaData
sqlParams.put("NODE_GROUP_ID", dataMetaData.getRouter().getNodeGroupLink()
.getTargetNodeGroupId());
sqlParams.put("EXTERNAL_DATA", dataMetaData.getData().getExternalData());
sqlParams.put("TABLE_NAME", dataMetaData.getData().getTableName());
ISqlTemplate template = symmetricDialect.getPlatform().getSqlTemplate();
List<String> ids = template.query(String.format("%s%s", sql, subSelect),
new StringMapper(), sqlParams);
Expand Down
Expand Up @@ -163,5 +163,15 @@ public long getEstimatedRowCount(Table table) {
return getSqlTemplateDirty().queryForLong("select ifnull(table_rows,-1) from information_schema.tables where table_name = ? and table_schema = ?",
table.getName(), table.getCatalog());
}

@Override
public boolean canColumnBeUsedInWhereClause(Column column) {
if ((column.getMappedTypeCode() == Types.VARBINARY && column.getSizeAsInt() <= 8000)
|| column.getMappedTypeCode() == Types.BINARY) {
return true;
}
return !column.isOfBinaryType();
}


}

0 comments on commit 17a39bc

Please sign in to comment.