|
|
|
WorkaroundJIRA uses the Open 4 Business (ofbiz) DB framework to provide cross platform database support. It defines its entities (tables) in a "virtual" database type and then these are "translated" into actual database types for each DB platform. So the definition of the "SearchRequest" entity (table) is as follows, taken from WEB-INF/classes/entitydefs/entitymodel.xml: <entity entity-name="SearchRequest" table-name="searchrequest" package-name="">
<field name="id" type="numeric"/>
<field name="name" col-name="filtername" type="long-varchar"/>
<field name="author" col-name="authorname" type="long-varchar"/>
<field name="description" type="very-long"/>
<field name="user" col-name="username" type="long-varchar"/>
<field name="group" col-name="groupname" type="long-varchar"/>
<field name="project" col-name="projectid" type="numeric"/>
<field name="request" col-name="reqcontent" type="very-long"/>
<prim-key field="id"/>
<relation type="one" title="Parent" rel-entity-name="Project">
<key-map field-name="project" rel-field-name="id"/>
</relation>
<index name="sr_author">
<index-field name="author"/>
</index>
<index name="sr_group">
<index-field name="group"/>
</index>
</entity>
The "request" field is defined as "very-long" and on Oracle 10G this translates to "varchar2(4000)", hence the 4K limit. Other databases map it to a longer type. For example, in MYSQL "very-long" maps to the MYSQL type of "text" which is 32K in size. So if something such as a filter definition that was greater than 4K was made in your old database, when it is exported and re-imported to Oracle is is bigger than the maximum allowed column size and hence the import fails. The workaround for this problem is to edit <jiradir>/WEB-INF/classes/entitydefs/entitymodel.xml and change the definition of the SearchRequest entity (around line 433) as follows to use "extremely-long": <entity entity-name="SearchRequest" table-name="searchrequest" package-name="">
<field name="id" type="numeric"/>
<field name="name" col-name="filtername" type="long-varchar"/>
<field name="author" col-name="authorname" type="long-varchar"/>
<field name="description" type="very-long"/>
<field name="user" col-name="username" type="long-varchar"/>
<field name="group" col-name="groupname" type="long-varchar"/>
<field name="project" col-name="projectid" type="numeric"/>
<field name="request" col-name="reqcontent" type="extremely-long"/>
<prim-key field="id"/>
<relation type="one" title="Parent" rel-entity-name="Project">
<key-map field-name="project" rel-field-name="id"/>
</relation>
<index name="sr_author">
<index-field name="author"/>
</index>
<index name="sr_group">
<index-field name="group"/>
</index>
</entity>
On Oracle 10g, "extremely-long" maps to the Oracle type CLOB which allows for very big column sizes. The down-side of this "workaround" is that it will have to be re-applied when the JIRA code base is updated, until the bug (this issue) is fixed. If this doesn't fix the problem, please create an issue in our support system, https://support.atlassian.com One caveat on the workaround is that it will only work IF the database it empty and JIRA re-creates the database table. If you have already started JIRA and hence the database table is created, it wont be be updated to the new column definition.
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
The data was exported from a JIRA instance using a database other than Oracle.