[rules-users] Decision tables - multiple params to function over multiple columns

2011-03-29 Thread Travis_Smith
Hi,

Currently I've got a consequence on a decision table that works like this:

callHelperFunction( $1, $2, $handleFromConditions);

where the first two parameters are strings, $1 being a code, $2 a 
description.

which means that you get the table holding things like:

DC X223,This is the description text which can be fairly wordy

That works just fine!

However: For ease of maintenance, the risk analysts want the input split 
over two columns, so is there any way of doing this? I'm trying to avoid 
inserting a temporary fact then cleaning it up after, if possible, as I 
can't see that being particularly good for performance.

Thank you,
-Trav

Travis Smith
Analyst Programmer
Development Centre
BNZ

DDI: +644 4746356 (Or Ext 76356)

CAUTION - This message may contain privileged and confidential information 
intended only for the use of the addressee named above. If you are not the 
intended recipient of this message you are hereby notified that any use, 
dissemination, distribution or reproduction of this message is prohibited. 
This email was sent by the Bank of New Zealand. You can contact us on 
0800 ASK BNZ (0800 275 269). Any views expressed in this message are those 
of the individual sender and may not necessarily reflect the views of Bank 
of New Zealand.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Decision tables - multiple params to function over multiple columns

2011-03-29 Thread Wolfgang Laun
I think this is more a Java question of how to call a method in instalments.

One option is to set a temporary from the 1st column, and call from
the 2nd: The first column might be
  String code = $param;
and the next column would
  callHelperFunction( code, $param, $handleFromConditions);
and the next column would

Alternatively, you can do
   startHelperFunction( $handle, $param );
   execHelperFunction( $param );
also with each statement coming from a column of its own.

With non-statics, also chained calls would be possible.

-W

2011/3/29  travis_sm...@bnz.co.nz:

 Hi,

 Currently I've got a consequence on a decision table that works like this:

         callHelperFunction( $1, $2, $handleFromConditions);

 where the first two parameters are strings, $1 being a code, $2 a
 description.

 which means that you get the table holding things like:

         DC X223,This is the description text which can be fairly wordy

 That works just fine!

 However: For ease of maintenance, the risk analysts want the input split
 over two columns, so is there any way of doing this? I'm trying to avoid
 inserting a temporary fact then cleaning it up after, if possible, as I
 can't see that being particularly good for performance.

 Thank you,
 -Trav

 Travis Smith
 Analyst Programmer
 Development Centre
 BNZ

 DDI: +644 4746356 (Or Ext 76356)

 CAUTION - This message may contain privileged and confidential information
 intended only for the use of the addressee named above. If you are not the
 intended recipient of this message you are hereby notified that any use,
 dissemination, distribution or reproduction of this message is prohibited.
 This email was sent by the Bank of New Zealand. You can contact us on
 0800 ASK BNZ (0800 275 269). Any views expressed in this message are those
 of the individual sender and may not necessarily reflect the views of Bank
 of New Zealand.

 ___
 rules-users mailing list
 rules-users@lists.jboss.org
 https://lists.jboss.org/mailman/listinfo/rules-users



___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Decision tables - multiple params to function over multiple columns

2011-03-29 Thread Travis_Smith
Thank you for the reply Wolfgang,

For some reason I had a mental blank when I asked that question - was 
thinking Can't create variables like that.

Thanks!
-Trav

Travis Smith
Analyst Programmer
Development Centre
BNZ

DDI: +644 4746356 (Or Ext 76356)





Wolfgang Laun wolfgang.l...@gmail.com
Sent by: rules-users-boun...@lists.jboss.org
29/03/2011 08:21 p.m.
Please respond to
Rules Users List rules-users@lists.jboss.org


To
Rules Users List rules-users@lists.jboss.org
cc

Subject
Re: [rules-users] Decision tables - multiple params to function over 
multiple columns




I think this is more a Java question of how to call a method in 
instalments.

One option is to set a temporary from the 1st column, and call from
the 2nd: The first column might be
  String code = $param;
and the next column would
  callHelperFunction( code, $param, $handleFromConditions);
and the next column would

Alternatively, you can do
   startHelperFunction( $handle, $param );
   execHelperFunction( $param );
also with each statement coming from a column of its own.

With non-statics, also chained calls would be possible.

-W

2011/3/29  travis_sm...@bnz.co.nz:

 Hi,

 Currently I've got a consequence on a decision table that works like 
this:

 callHelperFunction( $1, $2, $handleFromConditions);

 where the first two parameters are strings, $1 being a code, $2 a
 description.

 which means that you get the table holding things like:

 DC X223,This is the description text which can be fairly wordy

 That works just fine!

 However: For ease of maintenance, the risk analysts want the input split
 over two columns, so is there any way of doing this? I'm trying to avoid
 inserting a temporary fact then cleaning it up after, if possible, as I
 can't see that being particularly good for performance.

 Thank you,
 -Trav

 Travis Smith
 Analyst Programmer
 Development Centre
 BNZ

 DDI: +644 4746356 (Or Ext 76356)

 CAUTION - This message may contain privileged and confidential 
information
 intended only for the use of the addressee named above. If you are not 
the
 intended recipient of this message you are hereby notified that any use,
 dissemination, distribution or reproduction of this message is 
prohibited.
 This email was sent by the Bank of New Zealand. You can contact us on
 0800 ASK BNZ (0800 275 269). Any views expressed in this message are 
those
 of the individual sender and may not necessarily reflect the views of 
Bank
 of New Zealand.

 ___
 rules-users mailing list
 rules-users@lists.jboss.org
 https://lists.jboss.org/mailman/listinfo/rules-users



___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


CAUTION - This message may contain privileged and confidential information 
intended only for the use of the addressee named above. If you are not the 
intended recipient of this message you are hereby notified that any use, 
dissemination, distribution or reproduction of this message is prohibited. 
This email was sent by the Bank of New Zealand. You can contact us on 
0800 ASK BNZ (0800 275 269). Any views expressed in this message are those 
of the individual sender and may not necessarily reflect the views of Bank 
of New Zealand.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users