Display active incident records from the category hardware and software.?

ram2497
Tera Contributor

Display active incident records from the category hardware and software.

1 ACCEPTED SOLUTION

Archana Reddy2
Tera Guru

Hi Ram,

The below one may help you.

var arr=[];
var inc = new GlideRecord('incident');
inc.addActiveQuery();
inc.addEncodedQuery('category=software^ORcategory=hardware');
inc.query();
while(inc.next())
{
arr.push(inc.getValue('number'));
}
gs.print(arr); 

Hope this helps!

Thanks,

Archana

View solution in original post

6 REPLIES 6

Shashikant Yada
Tera Guru

Could you please explain the scenario, do you want to create the report?

yes

ScienceSoft
Tera Guru

You may display active incidents from these categories by setting up filter above you incidents list as following:

find_real_file.png

and you will get result: 

find_real_file.png

after this if you want to see report - right click on Category column and select Pie/Bar Char and this will create you report

find_real_file.png

find_real_file.png

Hi,

 

 Through Business rules.