xijunhu1982
2010-04-26 17:03
浏览 180
已采纳

关于jbpm4.3的问题

jbpm4.3中 Execution execution = executionService.findExecutionById(task1.getExecutionId());
其中task1.getExecutionId()取的值是leave.400001(leave是流程名),
但是findExecutionById这个方法取的是DBID_这个字段,对应数据库的值是400001,
这是怎么回事?

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

1条回答 默认 最新

  • wuhejian 2010-04-26 19:09
    已采纳

    executionService.findExecutionById 查询的不是你说的“DBID_”字段,而是“ID_”字段。
    [code="java"]
    public ClientExecution findExecutionById(String executionId) {
    // query definition can be found at the bottom of resource jbpm.pvm.execution.hbm.xml
    Query query = session.getNamedQuery("findExecutionById");
    query.setString("id", executionId);
    query.setMaxResults(1);
    return (ClientExecution) query.uniqueResult();
    }
    [/code]

    [code="java"]

    <![CDATA[
    select execution
    from org.jbpm.pvm.internal.model.ExecutionImpl as execution
    where execution.id = :id
    ]]>

    [/code]

    [code="java"]
    table="JBPM4_EXECUTION"
    discriminator-value="pvm">



    ...

    ...

    [/code]

    点赞 打赏 评论

相关推荐 更多相似问题