- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-28-2017 03:33 AM
How can I Query, via a script, all records irrespective of domain, from domain separated instance
Solved! Go to Solution.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-28-2017 03:35 AM
I think what you are looking for is "queryNoDomain()"
var abc = new GlideRecord('table');
abc.addQuery("field","value");
abc.queryNoDomain();
Will query ignoring the Domain.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-28-2017 03:35 AM
I think what you are looking for is "queryNoDomain()"
var abc = new GlideRecord('table');
abc.addQuery("field","value");
abc.queryNoDomain();
Will query ignoring the Domain.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-14-2018 07:01 AM
amazing! thanks man!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-28-2017 03:40 AM
var rec = new GlideRecord('incident');
rec.queryNoDomain();
while (rec.next()) {
gs.print(rec.number + ' exists');
}
let me know if it helps