```var supportcaseSearchObj = search.create({ t...
# suitescript
s
Copy code
var supportcaseSearchObj = search.create({
   type: "supportcase",
   filters:
   [
      ["employee.internalid","anyof",[219,8,10]]
   ],
   columns:
   [
      search.createColumn({
         name: "internalid",
         join: "employee",
         summary: "GROUP",
         label: "Internal ID"
      }),
      search.createColumn({
         name: "internalid",
         summary: "COUNT",
         label: "Internal ID"
      })
   ]
});
I want support case count assigned on employees and it's working fine, But I also want the employees with count '0' if it is not assigned to any but I passed in the filter. How can I achieve this?
m
Not sure if this is what you are asking for but the following would return those that match those ids and those unassigned.
Copy code
[
  ["employee.internalid","anyof",[219,8,10,"@NONE@"]]
]
b
This search is for support cases. You have to start the search from the employee record type if you want to include employees with no cases.
☝️ 1
Adding "@NONE@" to the filters would return support cases with no employees, not sure if that's what you want
s
thanks we don't have any link from emp record to support case
let me try by suiteql
e
You won't be able to search (or query) for the absence of Support Cases by searching on Support Cases alone; you'll have to combine a search of the Employees with your search of the Support Cases. In SuiteQL, you might be able to do that with a subquery or similar struct.
Here's the example from my Advanced Searching Cookbook that finds Employees with no Time Entries
1