Hello,
I'm looking for an sql query to retrieve statuses and their translations from database.
The "issuestatus" table doesn't have the translation column ! Any recommendation?
Regards,
Hi @Ahmadi Islem
It is a bit tricky because these translations are not stored in the issuestatus table. They are stored in a properties table, where they are associated with language-specific keys. Please take it with a pinch of salt but as far as I know, the translations are usually stored in the propertytext or propertyentry or propertystring tables, depending on the Jira version and database structure.
issuestatus
propertytext
propertyentry
propertystring
The property key for translations usually follows a specific pattern, such as jira.i18n.title or similar. I'd suggest using the following SQL as a starting point. However, please be aware that this query is not a complete, executable statement; rather it should be used as a foundation to build upon.
jira.i18n.title
SELECT iss.pname AS status_name, prop.key, text.propertyvalue AS translationFROM issuestatus issJOIN propertyentry prop ON prop.entity_id = iss.idJOIN propertytext text ON prop.id = text.idWHERE prop.entity_name = 'jira.issue.status' AND prop.property_key LIKE 'jira.i18n.title%'
Hi,
Just because it might help someone else. This sql query helped me to get all the translated jira statuses :
SELECT s.pname, pe.PROPERTY_KEY, ps.propertyvalueFROM issuestatus s, propertyentry pe, propertystring psWHERE pe.ENTITY_NAME = 'Status'AND pe.ID = ps.IDAND s.id = pe.ENTITY_ID
Hi @Tuncay Senturk _Snapbytes_ ,
Thank you for your suggestion.
You're very welcome, I hope it helps!
It looks like you're new here. Sign in or register to get started.