Attribute formula specific question


6 Commentaires

  • Chris Bulin
    Community Moderator

    Hi Vladimir Petrushenka You'll want to use the INCLUDES_ALL custom metric for tags. You can find the formula here: 

    Hope that helps!

  • Vladimir Petrushenka

    hi @... 

    Thanks for this. I probably didn't explain it well. So I want to: 

    1. Exclude tickets that contain tag1 tag2 tag3 

    2.To include tickets that contain both tags: tag1 tag4 

    3. I want to include all the rest tickets 

    I've tried this: 

     IF (NOT INCLUDES_ANY([Ticket tags], "tag1", "tag2", "tag3" )) AND (INCLUDES_ALL([Ticket tags], "tag1", "tag4"))
    THEN "true" ELSE "false" ENDIF

    But this isn't working unfortunately 


  • Chris Bulin
    Community Moderator

    Hi Vladimir. I don't think I understand why you would need both. If you exclude tickets with tags2 and 3, then what you're left with should be everything else (including tags 1 and 4). I don't think you need to explicitly say that you need to include tags 1 & 4. In the example you gave most recently tag1 is both in the exclude and include values, which is why that one won't work.

  • Julie Mathevet

    Hello Vladimir,

    If you want to create an attribute, I would recommend that you try this formula :

    IF (INCLUDES_ALL([Ticket tags], "tag1", "tag4")
    AND NOT(INCLUDES_ANY([Ticket tags], "tag2", "tag3")))
    ELIF (NOT(INCLUDES_ANY([Ticket tags], "tag1", "tag2", "tag3")))

    So you would select TRUE to see tickets that have tag1 AND tag4, or all tickets that don’t have tag1 (on its own), tag2, or tag3

    I hope this helps!

  • Vladimir Petrushenka

    Hi @... thanks for your reply. 

    Yeah, so that is the thing with the tags in our tickets, if I exclude the tag1 it will also exclude the tickets that contain tag1 AND tag4, but I want to see them in query. And the same time, i don't want to see tickets with tag1 on it's own(without tag4) 

    I appreciate it's too specific and not that straight forward. I've been trying to fix it for some time now. 

    @... thank you so much, I will give it a try today and will let you know if that works. 

    In the meantime, I've created 2 separate metrics. In one of them I exclude tag1 tag2 tag3 and include all the rest tickets, and in the other metric I include only tickets that have tag1 AND tag4. When I compound them into a stacked bar that gives me the data I'm looking for. However, the drawback for this set up is that I can't further slice this data for example by ticket channel, or by ticket tags. The chart looks rather messy when I'm trying to do that. 

    I'll try Julie's suggestion and will revert here. 

    Thanks again both! Much appreciate your help. 


  • Vladimir Petrushenka

    @... - you are legend :) that formula does work! thanks so much again for your help 


Vous devez vous connecter pour laisser un commentaire.

Réalisé par Zendesk