cancel
Showing results for 
Search instead for 
Did you mean: 

Error in setting up custom schema.

mann_frnd
Champ in-the-making
Champ in-the-making
HI

I manually created Schema under mssql DB also created the required table under the schema.

Following is the configuration.

<bean id="processEngineConfiguration" class="org.activiti.spring.SpringProcessEngineConfiguration">
  <property name="deploymentResources" value="classpath*:*.bpmn" />
 
    <property name="dataSource" ref="dataSource" />
    <property name="transactionManager" ref="transactionManager" />
    <property name="databaseSchemaUpdate" value="none" />
    <property name="jobExecutorActivate" value="false" />
    <property name="databaseSchema" value="Activiti" />
    <property name="databaseTablePrefix" value="Activiti." />
    <property name="tablePrefixIsSchema" value="true" />
</bean>


Now When I'm referring those tables with databaseTablePrefix property it's appeding this Activiti. to some of the Table. But not with all the tables.

Like it's not appending prefix with table ACT_ID_MEMBERSHIP.

Below is the generated query as it has not appended prefix Activiti. With ACT_ID_MEMBERSHIP so I’m getting the error table doesn’t exist.

SELECT SUB.*
FROM
  ( SELECT DISTINCT RES.* ,
    row_number() over (ORDER BY RES.ID_ ASC) rnk
  FROM
    ( SELECT DISTINCT RES.*
    FROM Activiti.ACT_RU_TASK RES
    LEFT JOIN Activiti.ACT_RU_IDENTITYLINK I
    ON I.TASK_ID_        = RES.ID_
    WHERE (RES.ASSIGNEE_ = ?
    OR (RES.ASSIGNEE_   IS NULL
    AND (I.USER_ID_      = ?
    OR I.GROUP_ID_      IN
      (SELECT g.GROUP_ID_ FROM ACT_ID_MEMBERSHIP g WHERE g.USER_ID_ = ?
      ) ) ) )
    )RES
  ) SUB
WHERE SUB.rnk >= ?
AND SUB.rnk    < ?

Please let me know the resolution to fix the above problem.

Thanks!
Aman
1 REPLY 1

jbarrez
Star Contributor
Star Contributor
Which query are you doing here, could you show the Java counterpart, so we know where to search?