5 Replies Latest reply on Feb 19, 2010 5:51 AM by lauretamisier

    Decision table

      Hello,

       

      Can we use a decision table instead of a drl file for rules with jBPM ?

       

      <rules-decision  name="soumettre">

       

      How I can do it ?

       

      Thanks & Regards

       

      Laure

        • 1. Re: Decision table
          sebastian.s
          AFAIK this is not possible since this is not yet implemented.
          • 2. Re: Decision table
            thanks for your answer !!
            • 3. Re: Decision table
              sebastian.s
              Just to clarify: It's not possible with the predefined activity but using a java task it should be possible. Maybe you also want to contribute or open a feature request in JIRA.
              • 4. Re: Decision table
                sebastian.s

                A quick search with google revealed that there is the possibility to convert a decision table to a .drl-file. So maybe that helps.

                 

                http://docs.codehaus.org/display/DROOLS/Decision+Tables

                1 of 1 people found this helpful
                • 5. Re: Decision table

                  In fact i have do it ... transform my decision table to a rule file .. is very simple :

                   

                  InputStream stream = null;

                          try {
                              stream = new FileInputStream(file);

                              SpreadsheetCompiler sCompiler = new SpreadsheetCompiler();

                              String drl = sCompiler.compile(stream, InputType.XLS);

                              File out = new File("toto.drl");

                              PrintWriter pw = new PrintWriter(out);

                              pw.append(drl);

                              pw.close();

                          } catch (IOException e) {
                              // TODO Auto-generated catch block
                              e.printStackTrace();
                          }