sure.. if you extend/configure the bam module to store that information you will be able to do all the queries that you need to find all those relationships.<div>Don&#39;t try to do that queries to the runtime tables that are optimized and store binary data.</div>
<div>Try also to avoid loading the process instance to do that kind of queries that can be easily externalized into another database or data structure that is more suited to answer those queries.</div><div><br></div><div>
Cheers</div><div><br><div class="gmail_quote">On Thu, Aug 11, 2011 at 2:46 PM, Burkhard Vogel <span dir="ltr">&lt;<a href="mailto:Burkhard.Vogel@modinter.com.ec">Burkhard.Vogel@modinter.com.ec</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">


  
  <div bgcolor="#FFFFFF" text="#000000">
    <font size="-1">Hi,<br>
    </font>I checked my process instance info table and all states are
    in 1 - what would be a condition that this changes to 2 (suspended)
    or 3 (ended) as currently all ended instances get deleted - is there
    a configuration option to accumulate these in a history table?<br>
    <br>
    <span style="font-weight:normal">R</span>elated to this - the only
    way to drill down from an process instance to the bottom most sub
    process instances current task is by loading it into the knowledge
    session and manually check if the node implements a subprocessnode
    instance and load that sub process instance and so forth until I get
    the last node which hasn&#39;t a node log with type 1?<span style="font-weight:bold;color:#204a87"> </span>Would there be
    a way to query from the process/node logs the current sub-process
    and current node?<br>
    <br>
    <span style="font-weight:normal"><font size="2"><font color="#204a87">T</font></font></span>o rephrase: I have the
    requirement to show in which state a current process is - which with
    the current console tools will only go as far as the parent flows
    current node - but that are almost always sub-processes, so what I&#39;d
    need is a way to build a query (or a set of queries) that would
    reflect the current process instance hierarchy and the current
    bottom most process/node.<br>
    <span style="font-weight:normal"></span><span style="font-weight:bold;color:#204a87"></span>I CAN do this by reading all current
    instances of a given parent task and afterwards do the individual
    drill-down until I reach the bottom most sub task - but this is
    desperately slow for thousands of instances, so I&#39;m looking for a DB
    select as I reckon all the info is in the audit tables.<br>
    <br>
    Best regards,<br>
    Burkhard<br>
    <div>-- <br>
      
      
      
      
      <p> Saludos cordiales,<br>
        <br>
        <span style="font-size:11pt"><strong>Burkhard Vogel</strong></span><br>
        <b>Lead Strategic Development</b><br>
        <br>
        <br>
        <img src="cid:part1.08040608.03040108@modinter.com.ec" name="131b9f38fad9a34c_modinter-logo" alt="modinter" align="bottom" border="0" height="46" width="155"><br>
        <b>Centre of Sales &amp; Support • Quito, Ecuador</b> </p>
      <p> Leonidas Plaza N24-318 y Baquerizo Moreno<br>
        Edificio Plaza 246<br>
        Phone:   <a href="tel:%2B593%202%202237393%20ext%207300" value="+59322237393" target="_blank">+593 2 2237393 ext 7300</a> </p>
      <p> Mobile:   <a href="tel:%2B593%209%205771800" value="+59395771800" target="_blank">+593 9 5771800</a><br>
        E-mail:    <a href="mailto:burkhard.vogel@modinter.com.ec" target="_blank">burkhard.vogel@modinter.com.ec</a>
      </p>
      <p> <a href="http://www.modinter.com.ec/" target="_blank"><strong>www.modinter.com.ec</strong></a>
      </p>
      <p> The information in this e-mail and any attachments
        is confidential and is intended for the addressee only and may
        contain confidential, proprietary or legally privileged
        information. If you are not the intended recipient, please
        delete this message and any attachments and advise the sender by
        return e-mail. Unless otherwise stated, any pricing or deliver
        information given in this message is indicative only, is subject
        to change and to formal communication.<br>
        FISA GROUP and each or any of its operating companies reserve
        the right to monitor all e-mail communication through its
        networks. </p>
    </div>
  </div>

<br>_______________________________________________<br>
jbpm-dev mailing list<br>
<a href="mailto:jbpm-dev@lists.jboss.org">jbpm-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/jbpm-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/jbpm-dev</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br> - CTO @ <a href="http://www.plugtree.com">http://www.plugtree.com</a>  <br> - MyJourney @ <a href="http://salaboy.wordpress.com">http://salaboy.wordpress.com</a><br>
 - Co-Founder @ <a href="http://www.jbug.com.ar">http://www.jbug.com.ar</a><br> <br> - Salatino &quot;Salaboy&quot; Mauricio -<br>
</div>