How to Fix the Column is of type TEXT in the database but defined as LONGTEXT in the entity definition Error
Symptoms
When JIRA starts the following error appears in the atlassian-jira.log
:
2013-03-18 21:33:51,136 main INFO [jira.config.database.SystemTenantDatabaseConfigurationLoader] Reading database configuration from /opt/atlassian/application-data/jira/dbconfig.xml
2013-03-18 21:33:51,417 main INFO [jira.config.database.DatabaseConfigurationManagerImpl] Now running Database Checklist Launcher
2013-03-18 21:33:56,928 main ERROR [core.entity.jdbc.DatabaseUtil] WARNING: Column "PROPERTYVALUE" of table "propertytext" of entity "OSPropertyText" is of type "TEXT" in the database, but is defined as type "LONGTEXT" in the entity definition.
2013-03-18 21:33:56,930 main ERROR [core.entity.jdbc.DatabaseUtil] WARNING: Column "REQCONTENT" of table "searchrequest" of entity "SearchRequest" is of type "TEXT" in the database, but is defined as type "LONGTEXT" in the entity definition.
Diagnosis
JIRA was upgraded using an in-place database upgrade from 3.1.x.
Cause
The database modification was not made during the in-place database upgrade, as historically JIRA used the XML restore method of upgrading rather than in-place upgrades. This was tracked in - JRA-14701Getting issue details... STATUS .
Resolution
As per our JIRA 4.0 Database Schema Changes for MySQL and Oracle docs, this can be fixed by altering the database. This does not have to be done at the time of the upgrade and can be executed any time after it.