We import our ClearQuest issues to JIRA while keeping the original issue key (by adding an ‘Issue Key’ column to the import CSV in the format: -)
Now we would like to make sure that new issues created in JIRA will be numbered starting from the highest ClearQuest ID. But there is no ‘official’ way to do it.
I finally found this article for jira 4.x which describes a way to do it via SQL, and it works well also for 5.2.9 (probably any 5.x version). Here is a summary of the required actions:
1. Stop JIRA
2. Get the project’s internal ID by running the following SQL command (in this example, the project key is ‘SAMPL’):
SELECT id FROM project WHERE pkey='SAMPL';
3. Update the counter by running the following SQL commands (in this example, the id is 10101, and we want to start the issue numbering from 15000):
UPDATE project SET pcounter='15000' WHERE id=10101; COMMIT;
4. Start JIRA.
5. Create an issue in the affected project – it should get the number you specified + 1.