I'm looking at the document that is called: How to merge two users' content ownership and permissions in Jira
If you look at Step 4, there are lot of queries that are written in PostgreSQL.
Our company is using MySQL and I'm not sure how to run some of queries in MySQL language.
Here are the queries that I'm struggling with:
update userassociation set source_name = tmp_app_user_migration.new_user_key from tmp_app_user_migration where source_name = tmp_app_user_migration.old_user_key
and sink_node_id not in (select U1.sink_node_id from userassociation U1, userassociation U2
where U1.source_name = tmp_app_user_migration.old_user_key and U2.source_name = tmp_app_user_migration.new_user_key and
U2.sink_node_id = U1.sink_node_id);
update userhistoryitem set username = tmp_app_user_migration.new_user_key from tmp_app_user_migration where username = tmp_app_user_migration.old_user_key
and entityid not in (select U1.entityid from userhistoryitem U1, userhistoryitem U2
where U1.username = tmp_app_user_migration.old_user_key and U2.username = tmp_app_user_migration.new_user_key
and U2.entityid = U1.entityid and U2.entitytype = U1.entitytype);
Can anyone help me with this?
Hi @JWCho,
Those SQLs looks like they are compatible with MySQL as well, can I know if you are having any errors executing those SQLs?
Thanks,
Moga
Thanks for the update @JWCho. It would have been helpful if you had provided the syntax error for troubleshooting.
Anyway, glad to know that it's resolved!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.