This article descibes how to add a user to the JIRA backend database (Microsoft SQL Server in our case)
We use this in our script that adds users from active directory to JIRA. Any comments welcome...
Create a record in userbase & membershipbase tables:
userbase
| ID | username | PASSWORD_HASH |
|---|---|---|
| 10100 | alitest | (null) |
So UserID = 10100 in our case
membershipbase
| ID | USER_NAME | GROUP_NAME |
|---|---|---|
| 10049 | alitest | jira-users |
Ignore the membershipID (10049)
Create property strings (just increment IDs)
| ID | propertyvalue |
|---|---|
| 10088 | alitest@test |
| 10089 | Ali Test |
Here 10088 is the emailID, and 10089 is the nameID
Now create property entries using the previously used IDs in ID column (emailID, nameID), and the UserID in the ENTITY_ID column
| ID | ENTITY_NAME | ENTITY_ID | PROPERTY_KEY | propertytype |
|---|---|---|---|---|
| 10088 | OSUser | 10100 | 5 | |
| 10089 | OSUser | 10100 | fullName | 5 |
Labels
(None)

Comments (2)
Dec 27, 2005
doggy mcdog says:
Here's the tsql I used to update the names of everyone in our jira backend from ...Here's the tsql I used to update the names of everyone in our jira backend from a table in another db with the username | fullnames:
Yes - cursors are not manly enough for most sql gurus, but they're very readable.
Feb 01, 2006
Aino Andriessen says:
Don't forget to update the OS... properties in the sequencevalueitem table. And ...Don't forget to update the OS... properties in the sequence_value_item table.
And restart Jira, else caching can (and will) prevent to show your new users.