Postgresql Query Syntax Error (Restoring Admin Password CentOS)



I'm following the directions listed within the following link to reset the admin password for our Confluence instance.


However when I run the below query (Using phpPgAdmin) I receive the syntax error shown in the screenshot. Any ideas as to what I'm doing wrong here?

insert into cwd_user(id, user_name, lower_user_name, active, created_date, updated_date, first_name, lower_first_name, last_name, lower_last_name, display_name, lower_display_name, email_address, lower_email_address, directory_id, credential) values (1212121, 'admin', 'admin', 'T', '2009-11-26 17:42:08', '2009-11-26 17:42:08', 'A. D.', 'a. d.', 'Ministrator', 'ministrator', 'A. D. Ministrator', 'a. d. ministrator', '', '', (select id from cwd_directory where directory_name='Confluence Internal Directory'), 'x61Ey612Kl2gpFL56FT9weDnpSo4AV8j8+qx2AuTHdRyY036xxzTTrw10Wq3+4qQyB+XURPWx1ONxp3Y3pB37A==');

insert into user_mapping values ('2c9681954172cf560000000000000001', 'admin', 'admin');

syntax error.PNG


I really appreciate everyone's help, I'm completely new to both Postgresql and JIRA, so I apologize if this is a simple question.



2 answers

1 accepted

1 vote
Ann Worley Atlassian Team Nov 08, 2017

It looks like the following has been appended to the front of the insert statement:

SELECT COUNT (*) as total FROM

Please try the queries without that, and let us know if you can add the user as expected. 

Thanks, Ann! 

It looks like the "Paginate Results" box was checked, which was appending the statement.


Unchecked the box, and now we're good to go!

Ann Worley Atlassian Team Nov 08, 2017

Thanks for following up with us for the sake of the next person who has that box checked. :) Happy to hear you're all set!


Have you selected the correct database first?

e.g: \c jiradb 

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Apr 13, 2018 in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

359 views 20 10
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you