You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by jb...@apache.org on 2017/06/16 18:35:18 UTC

lucene-solr:master: Ref Guide: Add floor evaluator docs

Repository: lucene-solr
Updated Branches:
  refs/heads/master c24e401d7 -> b49ce6893


Ref Guide: Add floor evaluator docs


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/b49ce689
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/b49ce689
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/b49ce689

Branch: refs/heads/master
Commit: b49ce68935805bdd00bb413291c5fab031a29c00
Parents: c24e401
Author: Joel Bernstein <jb...@apache.org>
Authored: Fri Jun 16 14:35:12 2017 -0400
Committer: Joel Bernstein <jb...@apache.org>
Committed: Fri Jun 16 14:35:12 2017 -0400

----------------------------------------------------------------------
 solr/solr-ref-guide/src/stream-evaluators.adoc | 20 ++++++++++++++++++--
 1 file changed, 18 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/b49ce689/solr/solr-ref-guide/src/stream-evaluators.adoc
----------------------------------------------------------------------
diff --git a/solr/solr-ref-guide/src/stream-evaluators.adoc b/solr/solr-ref-guide/src/stream-evaluators.adoc
index f10bca3..5d16fbf 100644
--- a/solr/solr-ref-guide/src/stream-evaluators.adoc
+++ b/solr/solr-ref-guide/src/stream-evaluators.adoc
@@ -244,13 +244,29 @@ The expressions below show the various ways in which you can use the `ceil` eval
 
 [source,text]
 ----
-ceil(100.4) // returns the remainder of 100.
+ceil(100.4) // returns 101.
 ceil(fieldA) // returns the next highest whole number for fieldA.
 if(gt(fieldA,fieldB),ceil(fieldA),ceil(fieldB)) // if fieldA > fieldB then return the ceil of fieldA, else return the ceil of fieldB.
 ----
 
 == floor
-//TODO
+The `floor` function rounds a decimal value to the next lowest whole number.
+
+=== floor Parameters
+
+* `Field Name | Raw Number | Number Evaluator`: The decimal to round down.
+
+=== floor Syntax
+
+The expressions below show the various ways in which you can use the `floor` evaluator.
+
+[source,text]
+----
+floor(100.4) // returns 100.
+ceil(fieldA) // returns the next lowestt whole number for fieldA.
+if(gt(fieldA,fieldB),floor(fieldA),floor(fieldB)) // if fieldA > fieldB then return the floor of fieldA, else return the floor of fieldB.
+----
+
 
 == sin
 //TODO