summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBin Feng2011-08-18 03:08:25 (EDT)
committer xgu2011-08-31 02:00:50 (EDT)
commit0f1718b703fd32ed5117925faaaf91de61ae7a19 (patch)
treede3546a74160fce96246c3ec607ad8880ad54a85
parentd8135133059901e26223a5e26e40cffc07a9e254 (diff)
downloadorg.eclipse.birt-0f1718b703fd32ed5117925faaaf91de61ae7a19.zip
org.eclipse.birt-0f1718b703fd32ed5117925faaaf91de61ae7a19.tar.gz
org.eclipse.birt-0f1718b703fd32ed5117925faaaf91de61ae7a19.tar.bz2
Make "between" filter consistent with SQL's "between" condition. [42136]
-rw-r--r--data/org.eclipse.birt.data/src/org/eclipse/birt/data/engine/script/ScriptEvalUtil.java15
1 files changed, 2 insertions, 13 deletions
diff --git a/data/org.eclipse.birt.data/src/org/eclipse/birt/data/engine/script/ScriptEvalUtil.java b/data/org.eclipse.birt.data/src/org/eclipse/birt/data/engine/script/ScriptEvalUtil.java
index 70ab624..50fe50f 100644
--- a/data/org.eclipse.birt.data/src/org/eclipse/birt/data/engine/script/ScriptEvalUtil.java
+++ b/data/org.eclipse.birt.data/src/org/eclipse/birt/data/engine/script/ScriptEvalUtil.java
@@ -556,19 +556,8 @@ public class ScriptEvalUtil
private static boolean between( Object resultObject, Object resultOp1,
Object resultOp2, CompareHints compareHints ) throws DataException
{
- Object min, max;
- if ( compare( resultOp1, resultOp2, compareHints ) <= 0 )
- {
- min = resultOp1;
- max = resultOp2;
- }
- else
- {
- min = resultOp2;
- max = resultOp1;
- }
- return compare( resultObject, min, compareHints ) >= 0
- && compare( resultObject, max, compareHints ) <= 0;
+ return compare( resultObject, resultOp1, compareHints ) >= 0
+ && compare( resultObject, resultOp2, compareHints ) <= 0;
}
/**