[jbpm-users] [JBoss jBPM] - Re: TaskInstance.setActorId(String) causes set TaskInstance

Octomac do-not-reply at jboss.com
Fri Jun 20 16:04:18 EDT 2008


I managed to find the problem, so I thought I'd come back here and post it just in case this helps anyone else.

The default JBPM database configuration uses the type "BIT" for boolean columns.  BIT doesn't map exactly correctly to Java's "true" and "false," or even 1 and 0.  As a result, no matter what data I placed into the database, JBPM and Hibernate would interpret it as "true."  So, whenever I called, say, TaskInstance.setActorId("Name"), the Hibernate query was inserting correct data to the database, but that data was being interpreted as a BIT value.

To correct the problem, I manually changed each BIT column to a TINYINT(1) type.  This ensured that the data Hibernate was passing into my database was interpreted correctly, and as a result, I am now able to handle assignment and creation of tasks correctly.

If anyone else experiences the same problem that I did, hopefully this will help.  Thanks again to the JBoss Forum members who assisted me in this matter!

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4159666#4159666

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4159666



More information about the jbpm-users mailing list