What's the mysql equivelant

This question is in reference to Atlassian Documentation: Update the corrupted Application Links

I need to clean up our database using this reference:  

https://confluence.atlassian.com/jirakb/update-the-corrupted-application-links-792635088.html

The search string works but the update string does not:

mysql> select * from propertyentry pe, propertystring ps where pe.id = ps.id and pe.property_key = 'applinks.global.application.ids';

mysql> update propertystring set propertyvalue = E'#java.util.List\n' where id = '27160';
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''#java.util.List\n' where id = '27160'' at line 1

2 answers

1 accepted

The uppercase E in front of the quoted string indicates that the \n should be escaped - I think its a Postgres-specific thing.

In the MySQL version of SQL you should remove that uppercase E so you get the following query: UPDATE propertystring SET propertyvalue = "#java.util.List\n" WHERE id = '27160';

Okay, thank you!  

I set up a test database and imported the sql data from JIRA to try it out.  It didn't like the double quotes either but you are correct that removing the E in front of the '#java did the trick.


mysql> UPDATE propertystring SET propertyvalue = “#java.util.List\n” where id = '27160';
-> ;
ERROR 1054 (42S22): Unknown column '“' in 'field list'


mysql> UPDATE propertystring SET propertyvalue = '#java.util.List\n' where id = '27160';
Query OK, 1 row affected (0.00 sec)
Rows matched: 1 Changed: 1 Warnings: 0

I'll have to wait until I can schedule down time again before I can implement it in production.  But at least now I have the proper commands to do so.

Thanks for you help!

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
Julia Dillon
Posted Tuesday in Jira

Tell us how your team runs on Jira!

Hey Atlassian Community! Today we are launching a bunch of customer stories about the amazing work teams, like Dropbox and Twilio, are doing with Jira. You can check out the stories here. The thi...

532 views 1 18
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