Im trying put a Jira data using the Jira using Jira filter and then use the table Filter.
I used this query
SELECT T1.'Summary' as 'Deliverables',
T1.'Status' as 'Status',
CASE
WHEN MATCH_REGEXP(T1.'Labels', 'mco')
THEN "MCO"
WHEN MATCH_REGEXP(T1.'Labels', 'cloud')
THEN "CLOUD"
WHEN MATCH_REGEXP(T1.'Labels', 'DE')
THEN "DE"
WHEN MATCH_REGEXP(T1.'Labels', 'k8s-Security-squad')
THEN "Security"
WHEN MATCH_REGEXP(T1.'Labels', 'ccm')
THEN "CCM"
WHEN MATCH_REGEXP(T1.'Labels', 'mms')
THEN "MMS"
WHEN MATCH_REGEXP(T1.'Labels', 'mls')
THEN "MLS"
ELSE "No Team"
END as 'Team', T1.'Assignee' as 'Owner',T1.'Due' as 'Due Date',T1.'Planned "Done" Date' as 'Planned Done Date'
FROM T1
ORDER BY T1.'Summary' ASC
The case is not working, its not able to match properly the label string, my label string have words "mco" , "Security" ,"DE" etc .
When the label is blank it satisfy the Else part but when there is value in the label it marks everything as MCO , no matter what the label is
Hi @gautamdey ,
The issue is in the function: use not MATCH_REGEXP(T1.'Labels', 'mco') but MATCH_REGEXP(T1.'Labels', "mco").
You should update every MATCH_REGEXP function in the query.
The 'mco' reference ( the ' ' quotes) means that you want to call out a column. The "mco" reference ( the " " quotes) means that you use a string in your query. And here our purpose is to find a specific string inside each cell.
thanks for your help it worked
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.