Auto Associate New Issue Key to its Epic Field does not Work

Still need help?

The Atlassian Community is here for you.

Ask the community

Symptoms

Function stated in Working with Epics in GreenHopper Classic does not work anymore:

5. Save the new card. If your project is using the 'Scrum' template, the new card's issue key will automatically appear in its 'Epic' field. If not, edit the new card and type its issue key into the 'Epic' field.

Cause

Epic/Theme custom field created during agile installation was deleted and newly created Epic customfield is no longer mapped to the SCRUM_DEFAULT_TEMPLATE_CONFIGURATION.

Resolution

  1. Shutdown JIRA.
  2. Run query below to retrieve the agile configuration:

    SELECT * FROM propertyentry p join propertytext s on p.id=s.id where p.entity_name="greenhopper" and p.property_key like "SCRUM%";

    You will get result like below :

    ID

    ENTITY_NAME

    ENTITY_ID

    PROPERTY_KEY

    propertytype

    ID

    propertyvalue

    10195

    GreenHopper

    1

    SCRUM_DEFAULT_TEMPLATE_CONFIGURATION

    6

    10195

    "<map> <entry> <string>gh.issue.story</string>...</map>"

    10205

    GreenHopper

    1

    SCRUM_CONFIGURATION

    6

    10205

    "<map> ...</map>"

  3. Next, run query below to delete any custom templates created (SCRUM_CONFIGURATION). Please note you will lose your custom template settingsuch as color, card setting, etc.

    delete from propertyentry  where  id=10205;
    
    delete from propertytext  where  id=10205;
    
  4. Copy and view the value from the SCRUM_DEFAULT_TEMPLATE_CONFIGURATION

    "<map>
      <entry>
        <string>gh.issue.story</string>
        <string>6</string>
      </entry>
      <entry>
        <string>gh.issue.storypoints</string>
        <string>customfield_10002</string>
      </entry>
      <entry>
        <string>gh.issue.rankingfield</string>
        <string>customfield_10001</string>
      </entry>
      <entry>
        <string>gh.issue.labelfield</string>
        <string>customfield_10010</string>
      </entry>
      <entry>
        <string>gh.issue.epic</string>
        <string>5</string>
      </entry>
      ...
      ...
      
    </map>"
    
  5. Find for gh.issue.labelfield and change the associate customfield Id from customfield_10010 and change it to customfield_10040 (find the custom field value via Administration >> Issue Fields >> Customfields >> Epic, mouse over to Edit and view the link detail for customfield id)
  6. Double check on other parameter value by following the previous step.
  7. Update the field with the edited value into the database e.g:

    update  propertytext set propertyvalue='"<map> ...edited_value... </map>"' where id=10195;
    
  8. Start JIRA and associate the project to Scrum Template again.
Last modified on Aug 15, 2013

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.