[rules-users] condition operator "||" give NPE in 6.0 but 5.x is fine

Wolfgang Laun wolfgang.laun at gmail.com
Wed Dec 25 02:50:15 EST 2013


Works fine in 6.0.0.
-W

On 25/12/2013, wtang <wtang at kana.com> wrote:
> I have a rule below and the "||" operator is giving me null pointer
> exception
> (NPE) when the rule is invoked.  This NPE problem is only happening is 6.0.
>
> This NPE problem does not happen in 5.x and runs without and issues in 5.x
>
> Is this a bug in Drools 6.0?
>
> Below is my simple rule:
>
> rule "rule using Map"
> dialect "mvel"
> 	when
>        $map: Map(
>        this["id"] == "1000" ||                  // "||" operator works fine
> in 5.x but gives NPE in 6.0
>        this["first"] == "Johna"
>        )
>     then
>         System.out.println("customer is: " + $map["first"] + " " +
> $map["last"]);
> end
>
> Please let me know if this is a bug in 6.0x.  thanks!
>
>
>
> --
> View this message in context:
> http://drools.46999.n3.nabble.com/condition-operator-give-NPE-in-6-0-but-5-x-is-fine-tp4027416.html
> Sent from the Drools: User forum mailing list archive at Nabble.com.
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>


More information about the rules-users mailing list