Symptoms

When you run the installer for v6.0 to upgrade from v5.4.0.4, the installation fails with the following error message:

Table or indexed view 'TST_ATTACHMENT' does not have a full-text index or user does not have permission to perform this action.

When you look in the installation log file you will see more detailed information logged:

While executing SQL command:
>>>  IF EXISTS (SELECT * FROM sysfulltextcatalogs ftc WHERE ftc.name = N'FT_ARTIFACTS')  BEGIN      DROP FULLTEXT INDEX ON TST_ATTACHMENT;  END  
<<<
Messages:
   Table or indexed view 'TST_ATTACHMENT' does not have a full-text index or user does not have permission to perform this action. [System.Data.SqlClient.SqlException]

SQL Messages:
   1: Table or indexed view 'TST_ATTACHMENT' does not have a full-text index or user does not have permission to perform this action.

This error often happens when you have the database set to have free text indexes and the freetext catalog exists, but some of the individual indexes is missing.

Solution

The solution is to run the following SQL command to delete all the existing freetext indexes and catalogs and let the installer create them from scratch:

DROP FULLTEXT INDEX ON TST_REQUIREMENT
GO
DROP FULLTEXT INDEX ON TST_TEST_CASE
GO
DROP FULLTEXT INDEX ON TST_INCIDENT
GO
DROP FULLTEXT INDEX ON TST_RELEASE
GO
DROP FULLTEXT INDEX ON TST_TEST_RUN
GO
DROP FULLTEXT INDEX ON TST_TASK
GO
DROP FULLTEXT INDEX ON TST_TEST_STEP
GO
DROP FULLTEXT INDEX ON TST_TEST_SET
GO
DROP FULLTEXT INDEX ON TST_AUTOMATION_HOST
GO
DROP FULLTEXT INDEX ON TST_ATTACHMENT
GO
DROP FULLTEXT INDEX ON TST_BUILD
GO
DROP FULLTEXT INDEX ON TST_RISK
GO
DROP FULLTEXT CATALOG [FT_ARTIFACTS]
GO

DROP FULLTEXT INDEX ON TST_REQUIREMENT_DISCUSSION
GO
DROP FULLTEXT INDEX ON TST_RELEASE_DISCUSSION
GO
DROP FULLTEXT INDEX ON TST_TASK_DISCUSSION
GO
DROP FULLTEXT INDEX ON TST_TEST_CASE_DISCUSSION
GO
DROP FULLTEXT INDEX ON TST_TEST_SET_DISCUSSION
GO
DROP FULLTEXT INDEX ON TST_INCIDENT_RESOLUTION
GO
DROP FULLTEXT INDEX ON TST_RISK_DISCUSSION
GO
DROP FULLTEXT CATALOG [FT_COMMENTS]
GO