thelabdude commented on a change in pull request #247:
URL: https://github.com/apache/solr/pull/247#discussion_r682995862



##########
File path: solr/core/src/java/org/apache/solr/handler/sql/SolrFilter.java
##########
@@ -278,6 +265,24 @@ protected String translateComparison(RexNode node) {
       }
     }
 
+    private String toEqualsClause(String key, RexLiteral value, RexNode node) {
+      SqlTypeName fieldTypeName = ((RexCall) 
node).getOperands().get(0).getType().getSqlTypeName();
+      String terms = toSolrLiteralForEquals(value, fieldTypeName).trim();
+
+      boolean wrappedQuotes = false;
+      if (!terms.startsWith("(") && !terms.startsWith("[") && 
!terms.startsWith("{")) {
+        terms = "\"" + terms + "\"";
+        wrappedQuotes = true;

Review comment:
       @madrob This is a good catch and I just fixed in this PR but could break 
out to its own if you feel strongly about not fixing it here ;-)




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org
For additional commands, e-mail: issues-h...@solr.apache.org

Reply via email to