A report that shows all closed tickets where the opened for responded after they were closed.

Tal5
Giga Guru

Hello everyone
I would appreciate any help

i want create report that shows all closed tickets where the opened for responded after they were closed.

 

Thanks in advance.

6 REPLIES 6

DanishS
Tera Contributor

If you need to use a scripted filter to check the response time, you can use a Business Rule or Script Include to calculate this. For example:

 

  var gr = new GlideRecord('incident');
  gr.addEncodedQuery('state=7'); // Assuming 7 is the state for 'Closed'
  gr.query();
  while (gr.next()) {
      if (gr.opened_for && gr.sys_updated_on > gr.closed_at) {
          // Add logic to include this record in the report
      }
  }

Tal5
Giga Guru

Can I get a more detailed explanation of how I set this up in the report?
I will attach a screenshot

 

thanks in advance

 

 

 

Udayrathore049
Tera Contributor

Database View

For a no-code approach (admin access needed), you can:

  1. Create a Database View joining:

    • incident table

    • sys_journal_field table (on element_id = incident.sys_id)

  2. Add filters:

    • incident.state = closed

    • sys_journal_field.sys_created_on > incident.closed_at

    • sys_journal_field.sys_created_by = incident.opened_for

Tal5
Giga Guru

@Udayrathore049 

Hi, thanks for the reply. I would appreciate your help.
I think I'm missing something.
I created a Database View as you mentioned, as can be seen in the image (1).
But I couldn't figure out where I place the filters as you mentioned later in the message.
Can you help me with this?

Thanks in advance.