Project import fails with Missing userKey from ApplicationUser id
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
Symptoms
When attempting project import, you see the following error on the UI :

The following appears in the atlassian-jira.log
:
2014-07-25 17:11:57,254 JiraTaskExectionThread-8 WARN anikolaev 1031x15937x1 1pto3n 10.250.147.170 /secure/admin/ProjectImportSelectProject.jspa [imports.project.handler.ChainedSaxHandler] Encountered a parsing exception.
com.atlassian.jira.exception.ParseException: Missing userKey from ApplicationUser id = 10000
at com.atlassian.jira.imports.project.handler.RegisterUserMapperHandler.handleApplicationUser(RegisterUserMapperHandler.java:66)
at com.atlassian.jira.imports.project.handler.RegisterUserMapperHandler.handleEntity(RegisterUserMapperHandler.java:203)
at com.atlassian.jira.imports.project.handler.ChainedSaxHandler.endTopLevelElement(ChainedSaxHandler.java:250)
at com.atlassian.jira.imports.project.handler.ChainedSaxHandler.endElement(ChainedSaxHandler.java:195)
at com.atlassian.jira.imports.project.handler.ChainedSaxHandler.endElement(ChainedSaxHandler.java:150)
at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
at org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source)
Diagnosis
Look into the data in the app_user table. There should be an empty row with the ID mentioned in the error message.
Use a database query as follows (don't forget to replace <ID_from_error> with the appropriate ID) to confirm.
Select * from app_user where id = <ID_from_error>
Cause
We are not sure about the cause of this. A direct database update can cause this.
Solution
Resolution
Always back up your data before making any database modifications. If possible, test any alter, insert, update, or delete SQL commands on a staging server first.
Stop JIRA
Run this query in the database :
delete from app_user where id = <ID_from_error>;
ℹ️ Replace <ID_from_error> with the id from the error message above.
Restart JIRA
Export the xml backup from JIRA.
Re-attempt the project import.
Was this helpful?